<?php
-/************************************************************************
- * MXChange v0.2.1 Start: 06/19/2004 *
- * ================ Last change: 06/19/2004 *
- * *
- * -------------------------------------------------------------------- *
- * File : what-admins_contact.php *
- * -------------------------------------------------------------------- *
- * Short description : Contact an admin through mail or message *
- * -------------------------------------------------------------------- *
- * Kurzbeschreibung : Admin per Mail oder Nachricht kontaktieren *
- * -------------------------------------------------------------------- *
- * *
- * -------------------------------------------------------------------- *
- * Copyright (c) 2003 - 2008 by Roland Haeder *
- * For more information visit: http://www.mxchange.org *
- * *
- * This program is free software; you can redistribute it and/or modify *
- * it under the terms of the GNU General Public License as published by *
- * the Free Software Foundation; either version 2 of the License, or *
- * (at your option) any later version. *
- * *
- * This program is distributed in the hope that it will be useful, *
- * but WITHOUT ANY WARRANTY; without even the implied warranty of *
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
- * GNU General Public License for more details. *
- * *
- * You should have received a copy of the GNU General Public License *
- * along with this program; if not, write to the Free Software *
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, *
- * MA 02110-1301 USA *
- ************************************************************************/
-
-// Some security stuff...
-if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
- $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
- require($INC);
-}
-
-// Add description as navigation point
-ADD_DESCR("admin", basename(__FILE__));
-
-if (($_POST['ok'] != '') && ($_GET['admin'] != ''))
-{
- // Send mail or message
- if ((EXT_IS_ACTIVE("msg")) && ($_POST['type'] == "msg"))
- {
- // Add message
- $msg = LOAD_EMAIL_TEMPLATE("admins_msg_contact_admin", $_POST['text'], "0");
- SEND_ADMIN_MESSAGE($_GET['admin'], ADMINS_MSG_FROM_ADMIN, $msg);
- }
- else
- {
- // Send mail
- $result = SQL_QUERY("SELECT email FROM "._MYSQL_PREFIX."_admins WHERE id='".$_GET['admin']."' LIMIT 1", __FILE__, __LINE__);
- list($email) = SQL_FETCHROW($result);
- $msg = LOAD_EMAIL_TEMPLATE("admins_mail_contact_admin", $_POST['text'], "0");
- SEND_EMAIL($email, ADMINS_MSG_FROM_ADMIN, $msg);
- }
- // Mail / message dropped
- LOAD_TEMPLATE("admin_settings_saved", false, ADMINS_ADMIN_CONTACTED);
-}
- elseif ($_GET['admin'] != '')
-{
- // Load contact form template
- define('__ADMIN', $_GET['admin']);
- if (EXT_IS_ACTIVE("msg"))
- {
- // Add option to select between mail and message
- define('ADMINS_MESSAGING_SELECTION', "<TR>
- <TD colspan=\"3\" align=\"center\" class=\"admin_title bottom2\" height=\"28\">".ADMINS_SELECT_CONTACT_TYPE."</TD>
-</TR>
-<TR><TD colspan=\"3\" class=\"seperator\"> </TD></TR>
-<TR>
- <TD align=\"right\"><INPUT type=\"radio\" name=\"type\" class=\"admin_normal\" value=\"mail\" checked> ".ADMINS_CONTACT_TYPE_MAIL."</TD>
- <TD width=\"10\" class=\"seperator\"> </TD>
- <TD><INPUT type=\"radio\" name=\"type\" class=\"admin_normal\" value=\"msg\"> ".ADMINS_CONTACT_TYPE_MSG."</TD>
-</TR>");
- }
- else
- {
- // Outout hidden input
- define('ADMINS_MESSAGING_SELECTION', "<TR>
- <TD colspan=\"3\" align=\"center\" class=\"admin_title bottom2\" height=\"28\">
- ".ADMINS_CONTACT_DEFAULT_MAIL."
- <INPUT type=\"hidden\" name=\"type\" value=\"mail\">
- </TD>
-</TR>");
- }
- LOAD_TEMPLATE("admin_admins_contact_form");
-}
- else
-{
- // Please select an admin!
- LOAD_TEMPLATE("admin_settings_saved", false, ADMINS_SELECT_ADMIN);
-}
-//
+// @DEPRECATED
?>