📄 alerts.php
字号:
<?php
// +-------------------------------------------------------------+
// | DeskPRO v [2.0.1 Production]
// | Copyright (C) 2001 - 2004 Headstart Solutions Limited
// | Supplied by WTN-WDYL
// | Nullified by WTN-WDYL
// | Distribution via WebForum, ForumRU and associated file dumps
// +-------------------------------------------------------------+
// | DESKPRO IS NOT FREE SOFTWARE
// +-------------------------------------------------------------+
// | License ID : Full Enterprise License =) ...
// | License Owner : WTN-WDYL Team
// +-------------------------------------------------------------+
// | $RCSfile: alerts.php,v $
// | $Date: 2004/02/10 01:34:30 $
// | $Revision: 1.18 $
// +-------------------------------------------------------------+
// | File Details:
// | - Technician alert preferences
// +-------------------------------------------------------------+
error_reporting(E_ALL ^ E_NOTICE);
// start file
require("./../global.php");
// globalise variables
$global = array (
array('id') // ticketid
);
rg($global);
tech_nav('settings');
// default do
$_REQUEST['do'] = trim($_REQUEST['do']);
if (!isset($_REQUEST['do']) or $_REQUEST['do'] == "") {
$_REQUEST['do'] = "view";
}
############################### CREATE TASK ###############################
if ($_REQUEST['do'] == "update") {
$db->query("UPDATE tech SET
alert_reply_your = '" . mysql_escape_string($_REQUEST[alert_reply_your]) . "',
alert_reply_cat = '" . mysql_escape_string($_REQUEST[alert_reply_cat]) . "',
alert_reply_all = '" . mysql_escape_string($_REQUEST[alert_reply_all]) . "',
alert_new_cat = '" . mysql_escape_string($_REQUEST[alert_new_cat]) . "',
alert_new_all = '" . mysql_escape_string($_REQUEST[alert_new_all]) . "',
alert_pm = '".mysql_escape_string($_REQUEST[alert_pm]) . "',
alert_sound = '".mysql_escape_string($_REQUEST[alert_sound]) . "',
alert_popup = '".mysql_escape_string($_REQUEST[alert_popup]) . "',
alert_frequency = '".mysql_escape_string($_REQUEST[alert_frequency]) . "',
selected_sound = '".mysql_escape_string($_REQUEST[selected_sound]) . "'
WHERE id = '$user[id]'"
);
$user = $db->query_return("SELECT * FROM tech WHERE id = '$user[id]'");
alert('Alerts Updated');
$_REQUEST['do'] = 'view';
}
############################### CREATE TASK ###############################
if ($_REQUEST['do'] == "view") {
$bit = form_radio_yn('alert_reply_your', '', $user[alert_reply_your]);
$table[] = array(table_thelp('<b>Your Replies</b>', 'Settings', 'Your Replies'), $bit);
$bit = form_radio_yn('alert_reply_cat', '', $user[alert_reply_cat]);
$table[] = array(table_thelp('<b>Your Categories</b>', 'Settings', 'Your Categories'), $bit);
$bit = form_radio_yn('alert_reply_all', '', $user[alert_reply_all]);
$table[] = array(table_thelp('<b>All Replies</b>', 'Settings', 'All Replies'), $bit);
$bit = form_radio_yn('alert_new_cat', '', $user[alert_new_cat]);
$table[] = array(table_thelp('<b>New Tickets In Your Categories</b>', 'Settings', 'New Tickets In Your Categories'), $bit);
$bit = form_radio_yn('alert_new_all', '', $user[alert_new_all]);
$table[] = array(table_thelp('<b>New Ticket</b>', 'Settings', 'New Ticket'), $bit);
$bit = form_radio_yn('alert_pm', '', $user[alert_pm]);
$table[] = array(table_thelp('<b>Private Message</b>', 'Settings', 'Private Messages'), $bit);
$bit = form_radio_yn('alert_sound', '', $user[alert_sound]) . '<BR>Play sound: ' . form_select('selected_sound', list_sounds(), '', $user['selected_sound']) . ' '
. "<A onClick=\"openWindow('./soundpop.php', 200, 200, 'soundpreview')\">Preview Sounds</A>";
$table[] = array(table_thelp('<b>ACTION: Play Sound</b>', 'Settings', 'ACTION: Play Sound'), $bit);
$bit = form_radio_yn('alert_popup', '', $user[alert_popup]);
$table[] = array(table_thelp('<b>ACTION: Alert Box</b>', 'Settings', 'ACTION: Alert Box'), $bit);
$bit = form_input('alert_frequency', $user[alert_frequency], 5);
$table[] = array(table_thelp('<b>Alert Frequency</b>', 'Settings', 'Alert Frequency'), $bit);
table_header('Set Alert Notification Settings', 'alerts.php', array('do' => 'update'));
table_content('', $table);
table_footer('Update Options');
}
tech_footer();
?>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -