// Add description as navigation point
ADD_DESCR("member", __FILE__);
-if ((!isset($_POST['ok'])) || (empty($_POST['qsummary']))) {
+if ((!IS_FORM_SENT()) || (!REQUEST_ISSET_POST(('qsummary')))) {
// Output form
LOAD_TEMPLATE("member_support_form");
} else {
// Load mail template based on your member's decision
if (GET_EXT_VERSION("admins") >= "0.4.1") {
- $a_tpl = "admin_support-".$_POST['qsummary'];
+ $a_tpl = "admin_support-".REQUEST_POST('qsummary');
} else {
- $msg_a = LOAD_EMAIL_TEMPLATE("admin_support-".$_POST['qsummary'], array('text' => $_POST['qdetails']), $GLOBALS['userid']);
+ $msg_a = LOAD_EMAIL_TEMPLATE("admin_support-".REQUEST_POST('qsummary'), array('text' => REQUEST_POST('qdetails')), $GLOBALS['userid']);
}
- $msg_m = LOAD_EMAIL_TEMPLATE("member_support-".$_POST['qsummary'], array('text' => $_POST['qdetails']), $GLOBALS['userid']);
+ $msg_m = LOAD_EMAIL_TEMPLATE("member_support-".REQUEST_POST('qsummary'), array('text' => REQUEST_POST('qdetails')), $GLOBALS['userid']);
// Select right subject
- switch ($_POST['qsummary']) {
+ switch (REQUEST_POST('qsummary')) {
case "ordr":
$subj_a = getMessage('SUPPORT_SUBJ_ADMIN_ORDER');
$subj_m = getMessage('SUPPORT_SUBJ_MEMBER_ORDER');
} // END - switch
// Send mail to admin
- SEND_ADMIN_NOTIFICATION($subj_a, $a_tpl, array('text' => $_POST['qdetails']), $GLOBALS['userid']);
+ SEND_ADMIN_NOTIFICATION($subj_a, $a_tpl, array('text' => REQUEST_POST('qdetails')), $GLOBALS['userid']);
// Send mail to user
SEND_EMAIL($GLOBALS['userid'], $subj_m, $msg_m);
// Drop a message in the admin's area
SQL_QUERY_ESC("INSERT INTO `{!_MYSQL_PREFIX!}_task_system` (userid, assigned_admin, status, task_type, subject, text, task_created) VALUES ('%s','0','NEW','SUPPORT_MEMBER','%s','%s', UNIX_TIMESTAMP())",
- array($GLOBALS['userid'], $subj_a, $_POST['qsummary'].":".array('text' => $_POST['qdetails'])), __FILE__, __LINE__);
+ array($GLOBALS['userid'], $subj_a, REQUEST_POST('qsummary').":".array('text' => REQUEST_POST('qdetails'))), __FILE__, __LINE__);
// Form sent
LOAD_TEMPLATE("member_support_contcted");