本文整理汇总了PHP中_QXZ函数的典型用法代码示例。如果您正苦于以下问题:PHP _QXZ函数的具体用法?PHP _QXZ怎么用?PHP _QXZ使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了_QXZ函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: mysql_to_mysqli
}
$rslt = mysql_to_mysqli($stmt, $link);
$result = _QXZ("SUCCESS");
$result_reason = _QXZ("pause_code function sent");
echo "{$result}: {$result_reason} - {$agent_user}\n";
$data = "{$epoch}";
api_log($link, $api_logging, $api_script, $user, $agent_user, $function, $value, $result, $result_reason, $source, $data);
} else {
$result = _QXZ("ERROR");
$result_reason = _QXZ("pause_code error - agent is not paused");
echo "{$result}: {$result_reason} - {$agent_user}\n";
api_log($link, $api_logging, $api_script, $user, $agent_user, $function, $value, $result, $result_reason, $source, $data);
}
} else {
$result = _QXZ("ERROR");
$result_reason = _QXZ("agent_user is not logged in");
echo "{$result}: {$result_reason} - {$agent_user}\n";
api_log($link, $api_logging, $api_script, $user, $agent_user, $function, $value, $result, $result_reason, $source, $data);
}
}
}
################################################################################
### END - pause_code
################################################################################
################################################################################
### BEGIN - optional "close window" link
################################################################################
if ($close_window_link > 0) {
$close_this_window_text = 'Close This Window';
if ($language == 'es') {
$close_this_window_text = 'Cerrar esta ventana';
示例2: _QXZ
if ($group == $group) {
$groups_list .= "<option selected value=\"{$rowx['0']}\">{$rowx['0']} - {$rowx['1']}</option>\n";
} else {
$groups_list .= "<option value=\"{$rowx['0']}\">{$rowx['0']} - {$rowx['1']}</option>\n";
}
$o++;
}
echo "{$groups_list}</select><br>\n";
echo _QXZ("status") . ": <input type=text name=status size=10 maxlength=10 value=\"{$status}\"> (" . _QXZ("example") . ": XFER)<br>\n";
echo _QXZ("date with hour") . ": <input type=text name=date_with_hour size=14 maxlength=13 value=\"{$date_with_hour}\"> (" . _QXZ("example") . ": 2004-06-25 14)<br>\n";
echo "<input type=submit name=submit value='" . _QXZ("SUBMIT") . "'>\n";
echo "<BR><BR><BR>\n";
$ENDtime = date("U");
$RUNtime = $ENDtime - $STARTtime;
echo "\n\n\n<br><br><br>\n\n";
echo "<font size=0>\n\n\n<br><br><br>\n" . _QXZ("script runtime") . ": {$RUNtime} " . _QXZ("seconds") . "</font>";
?>
</TD></TR></TABLE>
</body>
</html>
<?php
if ($db_source == 'S') {
mysqli_close($link);
$use_slave_server = 0;
$db_source = 'M';
require "dbconnect_mysqli.php";
}
$endMS = microtime();
示例3: _QXZ
if ($agent_ready > 9) {
$B = '<FONT class="b3">';
$BG = '</FONT>';
}
if ($agent_ready > 14) {
$B = '<FONT class="b4">';
$BG = '</FONT>';
}
echo "\n<BR>\n";
echo "{$NFB}{$agent_total}{$NFE} " . _QXZ("agents logged in") . " \n";
echo "{$NFB}{$agent_incall}{$NFE} " . _QXZ("agents in calls") . " \n";
echo "{$NFB}{$B} {$agent_ready} {$BG}{$NFE} " . _QXZ("agents waiting") . " \n";
echo "{$NFB}{$agent_paused}{$NFE} " . _QXZ("paused agents") . " \n";
echo "{$NFB}{$agent_dead}{$NFE} " . _QXZ("agents in dead calls") . " \n";
echo "{$NFB}{$agent_dispo}{$NFE} " . _QXZ("agents in dispo") . " \n";
echo "<PRE><FONT SIZE=2>";
echo "";
echo "{$Cecho}";
echo "{$Aecho}";
} else {
echo " " . _QXZ("NO AGENTS ON CALLS") . " \n";
echo "<PRE>{$Cecho}";
}
echo "</PRE>";
if ($RTajax < 1) {
echo "</TD></TR></TABLE>";
}
?>
</BODY></HTML>
示例4: lookup_gmt
function lookup_gmt($phone_code, $USarea, $state, $LOCAL_GMT_OFF_STD, $Shour, $Smin, $Ssec, $Smon, $Smday, $Syear, $postalgmt, $postal_code)
{
require "dbconnect_mysqli.php";
$postalgmt_found = 0;
if (preg_match("/POSTAL/i", $postalgmt) && strlen($postal_code) > 4) {
if (preg_match('/^1$/', $phone_code)) {
$stmt = "select postal_code,state,GMT_offset,DST,DST_range,country,country_code from vicidial_postal_codes where country_code='{$phone_code}' and postal_code LIKE \"{$postal_code}%\";";
$rslt = mysql_to_mysqli($stmt, $link);
$pc_recs = mysqli_num_rows($rslt);
if ($pc_recs > 0) {
$row = mysqli_fetch_row($rslt);
$gmt_offset = $row[2];
$gmt_offset = preg_replace("/\\+/i", "", $gmt_offset);
$dst = $row[3];
$dst_range = $row[4];
$PC_processed++;
$postalgmt_found++;
$post++;
}
}
}
if ($postalgmt_found < 1) {
$PC_processed = 0;
### UNITED STATES ###
if ($phone_code == '1') {
$stmt = "select country_code,country,areacode,state,GMT_offset,DST,DST_range,geographic_description from vicidial_phone_codes where country_code='{$phone_code}' and areacode='{$USarea}';";
$rslt = mysql_to_mysqli($stmt, $link);
$pc_recs = mysqli_num_rows($rslt);
if ($pc_recs > 0) {
$row = mysqli_fetch_row($rslt);
$gmt_offset = $row[4];
$gmt_offset = preg_replace("/\\+/i", "", $gmt_offset);
$dst = $row[5];
$dst_range = $row[6];
$PC_processed++;
}
}
### MEXICO ###
if ($phone_code == '52') {
$stmt = "select country_code,country,areacode,state,GMT_offset,DST,DST_range,geographic_description from vicidial_phone_codes where country_code='{$phone_code}' and areacode='{$USarea}';";
$rslt = mysql_to_mysqli($stmt, $link);
$pc_recs = mysqli_num_rows($rslt);
if ($pc_recs > 0) {
$row = mysqli_fetch_row($rslt);
$gmt_offset = $row[4];
$gmt_offset = preg_replace("/\\+/i", "", $gmt_offset);
$dst = $row[5];
$dst_range = $row[6];
$PC_processed++;
}
}
### AUSTRALIA ###
if ($phone_code == '61') {
$stmt = "select country_code,country,areacode,state,GMT_offset,DST,DST_range,geographic_description from vicidial_phone_codes where country_code='{$phone_code}' and state='{$state}';";
$rslt = mysql_to_mysqli($stmt, $link);
$pc_recs = mysqli_num_rows($rslt);
if ($pc_recs > 0) {
$row = mysqli_fetch_row($rslt);
$gmt_offset = $row[4];
$gmt_offset = preg_replace("/\\+/i", "", $gmt_offset);
$dst = $row[5];
$dst_range = $row[6];
$PC_processed++;
}
}
### ALL OTHER COUNTRY CODES ###
if (!$PC_processed) {
$PC_processed++;
$stmt = "select country_code,country,areacode,state,GMT_offset,DST,DST_range,geographic_description from vicidial_phone_codes where country_code='{$phone_code}';";
$rslt = mysql_to_mysqli($stmt, $link);
$pc_recs = mysqli_num_rows($rslt);
if ($pc_recs > 0) {
$row = mysqli_fetch_row($rslt);
$gmt_offset = $row[4];
$gmt_offset = preg_replace("/\\+/i", "", $gmt_offset);
$dst = $row[5];
$dst_range = $row[6];
$PC_processed++;
}
}
}
### Find out if DST to raise the gmt offset ###
$AC_GMT_diff = $gmt_offset - $LOCAL_GMT_OFF_STD;
$AC_localtime = mktime($Shour + $AC_GMT_diff, $Smin, $Ssec, $Smon, $Smday, $Syear);
$hour = date("H", $AC_localtime);
$min = date("i", $AC_localtime);
$sec = date("s", $AC_localtime);
$mon = date("m", $AC_localtime);
$mday = date("d", $AC_localtime);
$wday = date("w", $AC_localtime);
$year = date("Y", $AC_localtime);
$dsec = $hour * 3600 + $min * 60 + $sec;
$AC_processed = 0;
if (!$AC_processed and $dst_range == 'SSM-FSN') {
if ($DBX) {
print " " . _QXZ("Second Sunday March to First Sunday November") . "\n";
}
#**********************************************************************
# SSM-FSN
# This is returns 1 if Daylight Savings Time is in effect and 0 if
//.........这里部分代码省略.........
示例5: _QXZ
echo "<tr bgcolor=#B6D3FC><td align=right>" . _QXZ("Run") . ": </td><td align=left><input type=text name=run size=5 maxlength=4></td></tr>\n";
echo "<tr bgcolor=#B6D3FC><td align=right>" . _QXZ("Batch") . ": </td><td align=left><input type=text name=batch size=6 maxlength=5></td></tr>\n";
echo "<tr bgcolor=#B6D3FC><td align=right>" . _QXZ("Sequence") . ": </td><td align=left><input type=text name=sequence size=6 maxlength=5></td></tr>\n";
echo "<tr bgcolor=#B6D3FC><td align=center colspan=2><input type=submit name=SUBMIT value='" . _QXZ("SUBMIT") . "'></td></tr>\n";
echo "</TABLE></center>\n";
echo "\n";
echo "</center>\n";
}
### END search
?>
<BR><font size=1><?php
echo _QXZ("CallCard");
?>
<?php
echo _QXZ("VERSION");
?>
: <?php
echo $version;
?>
<?php
echo _QXZ("BUILD");
?>
: <?php
echo $build;
?>
</td></tr>
</TD></TR></TABLE>
示例6: Copyright
<?php
# welcome.php - VICIDIAL welcome page
#
# Copyright (C) 2014 Matt Florell <vicidial@gmail.com> LICENSE: AGPLv2
#
# CHANGELOG:
# 141007-2140 - Finalized adding QXZ translation to all admin files
header("Content-type: text/html; charset=utf-8");
require "functions.php";
echo "<title>" . _QXZ("ViciDial Welcome") . "</title>\n";
echo "</head>\n";
echo "<BODY BGCOLOR=WHITE MARGINHEIGHT=0 MARGINWIDTH=0>\n";
echo "<BR><BR><BR><BR><BR><CENTER><TABLE WIDTH=300 CELLPADDING=0 CELLSPACING=0 BGCOLOR=\"#CCCCCC\"><TR BGCOLOR=WHITE>";
echo "<TD ALIGN=LEFT VALIGN=BOTTOM><IMG SRC=\"../agc/images/vdc_tab_vicidial.gif\" BORDER=0></TD>";
echo "<TD ALIGN=CENTER VALIGN=MIDDLE> " . _QXZ("Welcome") . " </TD>";
echo "</TR>\n";
echo "<TR><TD ALIGN=CENTER COLSPAN=2><font size=1> </TD></TR>\n";
echo "<TR><TD ALIGN=CENTER COLSPAN=2><font size=3><b> <a href=\"../agc/vicidial.php\">" . _QXZ("Agent Login") . "</a> </TD></TR>\n";
echo "<TR><TD ALIGN=CENTER COLSPAN=2><font size=1> </TD></TR>\n";
echo "<TR><TD ALIGN=CENTER COLSPAN=2><font size=3><b> <a href=\"../agc/timeclock.php?referrer=welcome\"> " . _QXZ("Timeclock") . "</a> </TD></TR>\n";
echo "<TR><TD ALIGN=CENTER COLSPAN=2><font size=1> </TD></TR>\n";
echo "<TR><TD ALIGN=CENTER COLSPAN=2><font size=3><b> <a href=\"../vicidial/admin.php\">" . _QXZ("Administration") . "</a> </TD></TR>\n";
echo "<TR><TD ALIGN=CENTER COLSPAN=2><font size=1> </TD></TR>\n";
echo "</TABLE>\n";
echo "</FORM>\n\n";
echo "</body>\n\n";
echo "</html>\n\n";
示例7: _QXZ
$query_date_BEGIN = "{$query_date} 00:00:00";
$query_date_END = "{$end_date} 23:59:59";
$MAIN .= _QXZ("Inbound Summary Hourly Report") . ": {$group_string} {$NOW_TIME}\n";
$CSV_main .= _QXZ("Inbound Summary Hourly Report") . ":,{$NOW_TIME}\n";
$JS_text .= "<script language='Javascript'>\n";
$JS_onload = "onload = function() {\n";
if ($group_ct > 0) {
$ASCII_text .= "\n";
$ASCII_text .= "---------- " . _QXZ("MULTI-GROUP BREAKDOWN") . ":\n";
$ASCII_text .= "+------------------------------------------+--------+--------+-----------+---------+-----------+---------+---------+--------+\n";
$ASCII_text .= "| | | | | | " . _QXZ("TOTAL", 9) . " | " . _QXZ("AVERAGE", 7) . " | " . _QXZ("MAXIMUM", 7) . " | " . _QXZ("TOTAL", 6) . " |\n";
$ASCII_text .= "| | " . _QXZ("TOTAL", 6) . " | " . _QXZ("TOTAL", 6) . " | " . _QXZ("TOTAL", 9) . " | " . _QXZ("AVERAGE", 7) . " | " . _QXZ("QUEUE", 9) . " | " . _QXZ("QUEUE", 7) . " | " . _QXZ("QUEUE", 7) . " | " . _QXZ("ABANDON", 7) . "|\n";
$ASCII_text .= "| " . _QXZ("IN-GROUP", 40) . " | " . _QXZ("CALLS", 6) . " | " . _QXZ("ANSWER", 6) . " | " . _QXZ("TALK", 9) . " | " . _QXZ("TALK", 7) . " | " . _QXZ("TIME", 9) . " | " . _QXZ("TIME", 7) . " | " . _QXZ("TIME", 7) . " | " . _QXZ("CALLS", 6) . " |\n";
$ASCII_text .= "+------------------------------------------+--------+--------+-----------+---------+-----------+---------+---------+--------+\n";
$CSV_main .= "\"" . _QXZ("MULTI-GROUP BREAKDOWN") . ":\"\n";
$CSV_main .= "\"" . _QXZ("IN-GROUP") . "\",\"" . _QXZ("TOTAL CALLS") . "\",\"" . _QXZ("TOTAL ANSWER") . "\",\" " . _QXZ("TOTAL TALK") . "\",\" " . _QXZ("AVERAGE TALK") . "\",\" " . _QXZ("TOTAL QUEUE TIME") . "\",\" " . _QXZ("AVERAGE QUEUE TIME") . "\",\" " . _QXZ("MAXIMUM QUEUE TIME") . "\",\" " . _QXZ("TOTAL ABANDON CALLS") . "\"\n";
$CSV_subreports = "";
$graph_stats = array();
$max_calls = 1;
$max_answer = 1;
$max_talk = 1;
$max_avgtalk = 1;
$max_queue = 1;
$max_avgqueue = 1;
$max_maxqueue = 1;
$max_totalabandons = 1;
$GRAPH = "<BR><BR><a name='multigroup_graph'/><table border='0' cellpadding='0' cellspacing='2' width='800'>";
$GRAPH .= "<tr><th width='12%' class='grey_graph_cell' id='multigroup_graph1'><a href='#' onClick=\"DrawGraph('CALLS', '1'); return false;\">TOTAL CALLS</a></th><th width='12%' class='grey_graph_cell' id='multigroup_graph2'><a href='#' onClick=\"DrawGraph('ANSWER', '2'); return false;\">TOTAL ANSWER</a></th><th width='12%' class='grey_graph_cell' id='multigroup_graph3'><a href='#' onClick=\"DrawGraph('TALK', '3'); return false;\">TOTAL TALK</a></th><th width='12%' class='grey_graph_cell' id='multigroup_graph4'><a href='#' onClick=\"DrawGraph('AVGTALK', '4'); return false;\">AVERAGE TALK</a></th><th width='13%' class='grey_graph_cell' id='multigroup_graph5'><a href='#' onClick=\"DrawGraph('QUEUE', '5'); return false;\">TOTAL QUEUE TIME</a></th><th width='13%' class='grey_graph_cell' id='multigroup_graph6'><a href='#' onClick=\"DrawGraph('AVGQUEUE', '6'); return false;\">AVERAGE QUEUE TIME</a></th><th width='13%' class='grey_graph_cell' id='multigroup_graph7'><a href='#' onClick=\"DrawGraph('MAXQUEUE', '7'); return false;\">MAXIMUM QUEUE TIME</a></th><th width='13%' class='grey_graph_cell' id='multigroup_graph8'><a href='#' onClick=\"DrawGraph('TOTALABANDONS', '8'); return false;\">TOTAL ABANDON CALLS</a></th></tr>";
$GRAPH .= "<tr><td colspan='8' class='graph_span_cell'><span id='multigroup_stats_graph'><BR> <BR></span></td></tr></table><BR><BR>";
$graph_header = "<table cellspacing='0' cellpadding='0' class='horizontalgraph'><caption align='top'>INBOUND SERVICE LEVEL REPORT</caption><tr><th class='thgraph' scope='col'>IN-GROUP</th>";
$CALLS_graph = $graph_header . "<th class='thgraph' scope='col'>TOTAL CALLS </th></tr>";
示例8: _QXZ
echo "<font class=\"select_bold\"><B>" . _QXZ("User Groups") . ":</B></font><BR><CENTER>\n";
echo "<SELECT SIZE=20 NAME=user_group[] multiple>\n";
$o = 0;
while ($user_groups_to_print > $o) {
if (preg_match("/\\|{$LISTuser_groups[$o]}\\|/", $user_group_string)) {
echo "<option selected value=\"{$LISTuser_groups[$o]}\">{$LISTuser_groups[$o]}</option>\n";
} else {
echo "<option value=\"{$LISTuser_groups[$o]}\">{$LISTuser_groups[$o]}</option>\n";
}
$o++;
}
echo "</SELECT>\n";
}
echo "</TD></TR><TR></TD><TD ALIGN=LEFT VALIGN=TOP COLSPAN=2> \n";
echo "</TD></TR><TR></TD><TD ALIGN=CENTER VALIGN=TOP COLSPAN=5>\n";
echo "<INPUT TYPE=SUBMIT NAME=SUBMIT VALUE='" . _QXZ("SUBMIT") . "'>\n";
echo "</TD></TR></TABLE>\n";
echo "</FORM>\n\n";
}
if ($db_source == 'S') {
mysqli_close($link);
$use_slave_server = 0;
$db_source = 'M';
require "dbconnect_mysqli.php";
}
$endMS = microtime();
$startMSary = explode(" ", $startMS);
$endMSary = explode(" ", $endMS);
$runS = $endMSary[0] - $startMSary[0];
$runM = $endMSary[1] - $startMSary[1];
$TOTALrun = $runS + $runM;
示例9: _QXZ
echo "<td align=left><select size=5 id=custom_reports_user_groups" . $id . " name=custom_reports_user_groups" . $id . " multiple><option value='---ALL---'>" . _QXZ("ALL USER GROUPS") . "</option>";
$stmt = "SELECT user_group,group_name from vicidial_user_groups {$whereLOGadmin_viewable_groupsSQL} order by user_group;";
$rslt = mysql_to_mysqli($stmt, $link);
$usergroups_to_print = mysqli_num_rows($rslt);
$i = 0;
while ($i < $usergroups_to_print) {
$ug_row = mysqli_fetch_row($rslt);
if (in_array("{$ug_row['0']}", $UGarray)) {
$x = "selected";
} else {
$x = "";
}
echo "<option value='{$ug_row['0']}' {$x}>{$ug_row['1']}</option>";
$i++;
}
echo "<td align='center'><input type='button' value='" . _QXZ("UPDATE") . "' onClick=\"SubmitIDValues({$id})\"><BR><BR><a href='vicidial_custom_reports_admin.php?delete_custom_report=" . $id . "'>" . _QXZ("DELETE") . "</a></td>";
echo "</tr>\n";
}
}
echo "</table>";
echo "<input type=hidden name='upd_custom_report_id' id='upd_custom_report_id'>";
echo "<input type=hidden name='upd_report_name' id='upd_report_name'>";
echo "<input type=hidden name='upd_domain' id='upd_domain'>";
# echo "<input type=hidden name='upd_slave' id='upd_slave'>";
echo "<input type=hidden name='upd_path_name' id='upd_path_name'>";
echo "<input type=hidden name='upd_custom_reports_user_groups' id='upd_custom_reports_user_groups'>";
echo "</form>";
echo "</TD></TR></TABLE>\n";
echo "</BODY></HTML>";
?>
示例10: _QXZ
$CSV_text .= "\"{$count_count[$o]}\",";
}
$o++;
}
if (!$called_printed) {
$MAIN .= "<td {$AB}><font size=1> </td>";
$CSV_text .= "\"\",";
}
$first++;
}
$MAIN .= "<td><font size=1>{$leads_in_sts[$sts]}</td></tr>\n\n";
$CSV_text .= "\"{$leads_in_sts[$sts]}\"\n";
$sts++;
}
$MAIN .= "<tr><td align=center colspan=2><b><font size=1>" . _QXZ("TOTAL") . "</td>";
$CSV_text .= "\"\",\"" . _QXZ("TOTAL") . "\",";
$first = $all_called_first;
while ($first <= $all_called_last) {
if (preg_match('/1$|3$|5$|7$|9$/i', $first)) {
$AB = 'bgcolor="#AFEEEE"';
} else {
$AB = 'bgcolor="#E0FFFF"';
}
$MAIN .= "<td align=center {$AB}><b><font size=1>{$all_called_count[$first]}</td>";
$CSV_text .= "\"{$all_called_count[$first]}\",";
$first++;
}
$MAIN .= "<td align=center><b><font size=1>{$leads_in_list}</td></tr>\n";
$CSV_text .= "\"{$leads_in_list}\",";
$MAIN .= "</table></center><br>\n";
$MAIN .= "</BODY></HTML>\n";
示例11: is_user_logged_in
function is_user_logged_in($user)
{
global $link;
$stmt = "select status from vicidial_live_agents where user='{$user}'";
if ($DB) {
echo "|{$stmt}|\n";
}
$rslt = mysql_to_mysqli($stmt, $link);
$live_agent_count = mysqli_num_rows($rslt);
if ($live_agent_count != '1') {
if ($live_agent_count == '0') {
return _QXZ("Cannot call prospect. You are not logged in as") . " {$user}.";
} else {
return _QXZ("Cannot call prospect") . ". {$live_agent_count} " . _QXZ("agents logged in as") . " {$user}.";
}
}
$row = mysqli_fetch_row($rslt);
$status = $row[0];
if ($status != 'PAUSED') {
return _QXZ("Status must be paused to call lead") . ". {$user} " . _QXZ("is presently in") . " {$status} " . _QXZ("status") . ".";
}
//@TODO: check user is in the correct CAMPAIGN for this lead.
return true;
}
示例12: delete_field_function
function delete_field_function($DB, $link, $linkCUSTOM, $ip, $user, $table_exists, $field_id, $list_id, $field_label, $field_name, $field_description, $field_rank, $field_help, $field_type, $field_options, $field_size, $field_max, $field_default, $field_required, $field_cost, $multi_position, $name_position, $field_order, $vicidial_list_fields)
{
$SQLexecuted = 0;
if ($field_type == 'DISPLAY' or $field_type == 'SCRIPT' or preg_match("/\\|{$field_label}\\|/i", $vicidial_list_fields)) {
if ($DB) {
echo "Non-DB {$field_type} field type, {$field_label}\n";
}
$SQLexecuted++;
} else {
$stmtCUSTOM = "ALTER TABLE custom_{$list_id} DROP {$field_label};";
$rsltCUSTOM = mysql_to_mysqli($stmtCUSTOM, $linkCUSTOM);
$table_update = mysqli_affected_rows($linkCUSTOM);
if ($DB) {
echo "{$table_update}|{$stmtCUSTOM}\n";
}
if (!$rsltCUSTOM) {
echo _QXZ("Could not execute") . ': ' . mysqli_error() . "|{$stmtCUSTOM}|<BR><B>" . _QXZ("FIELD NOT DELETED, PLEASE GO BACK AND TRY AGAIN") . "</b>";
### LOG INSERTION Admin Log Table ###
$SQL_log = "{$stmt}|{$stmtCUSTOM}";
$SQL_log = preg_replace('/;/', '', $SQL_log);
$SQL_log = addslashes($SQL_log);
$stmt = "INSERT INTO vicidial_admin_log set event_date=NOW(), user='{$user}', ip_address='{$ip}', event_section='CUSTOM_FIELDS', event_type='OTHER', record_id='{$list_id}', event_code='ADMIN DELETE CUSTOM LIST FIELD ERROR', event_sql=\"{$SQL_log}\", event_notes='DELETE ERROR:" . mysqli_error() . "';";
if ($DB) {
echo "|{$stmt}|\n";
}
$rslt = mysql_to_mysqli($stmt, $link);
} else {
$SQLexecuted++;
}
}
if ($SQLexecuted > 0) {
$stmt = "DELETE FROM vicidial_lists_fields WHERE field_label='{$field_label}' and field_id='{$field_id}' and list_id='{$list_id}' LIMIT 1;";
$rslt = mysql_to_mysqli($stmt, $link);
$field_update = mysqli_affected_rows($link);
if ($DB) {
echo "{$field_update}|{$stmt}\n";
}
if (!$rslt) {
echo _QXZ("Could not execute") . ': ' . mysqli_error() . "|{$stmt}|";
}
### LOG INSERTION Admin Log Table ###
$SQL_log = "{$stmt}|{$stmtCUSTOM}";
$SQL_log = preg_replace('/;/', '', $SQL_log);
$SQL_log = addslashes($SQL_log);
$stmt = "INSERT INTO vicidial_admin_log set event_date=NOW(), user='{$user}', ip_address='{$ip}', event_section='CUSTOM_FIELDS', event_type='DELETE', record_id='{$list_id}', event_code='ADMIN DELETE CUSTOM LIST FIELD', event_sql=\"{$SQL_log}\", event_notes='';";
if ($DB) {
echo "|{$stmt}|\n";
}
$rslt = mysql_to_mysqli($stmt, $link);
}
return $SQLexecuted;
}
示例13: sprintf
$TOTALS_array[$x] = sprintf("%0.2f", MathZDC(100 * $TOTALS_array[$x - 1], $TOTALS_array[$x - 2]));
$x++;
$CSV_text .= "\"{$val[$x]}\",";
$ASCII_text .= " " . sprintf("%12s", $val[$x]) . " |";
$x++;
$CSV_text .= "\"" . sec_convert($val[$x], 'H') . "\",";
$ASCII_text .= " " . sprintf("%9s", sec_convert($val[$x], 'H')) . " ||";
$TOTALS_array[$x] += $val[$x];
$TOTALS_array[$x - 1] = sprintf("%0.2f", MathZDC($TOTALS_array[$x - 3], MathZDC($TOTALS_array[$x], 3600)));
# Go back to get last result
}
$ASCII_text .= "\n";
$CSV_text .= "\n";
}
$ASCII_text .= $ASCII_header2;
$CSV_text .= '"","' . _QXZ("TOTALS") . '",';
$ASCII_text .= "| " . sprintf("%26s", $TOTALS_array[0]) . " ||";
$GRAPH_text .= $GRAPH . $GRAPH2 . $GRAPH3;
for ($i = 1; $i < count($TOTALS_array); $i++) {
$CSV_text .= "\"{$TOTALS_array[$i]}\",";
switch ($i % 5) {
case "1":
case "2":
$ASCII_text .= " " . sprintf("%5s", $TOTALS_array[$i]) . " |";
break;
case "3":
$ASCII_text .= " " . sprintf("%10s", $TOTALS_array[$i]) . "% |";
break;
case "4":
$ASCII_text .= " " . sprintf("%12s", $TOTALS_array[$i]) . " |";
break;
示例14: sprintf
if ($call_time_SEC < 10) {
$call_time_SEC = "0{$call_time_SEC}";
}
$call_time_MS = "{$call_time_M_int}:{$call_time_SEC}";
$call_time_MS = sprintf("%7s", $call_time_MS);
$G = '';
$EG = '';
if (preg_match("/LIVE/i", $status)) {
$G = '<SPAN class="green"><B>';
$EG = '</B></SPAN>';
}
# if ($call_time_M_int >= 6) {$G='<SPAN class="red"><B>'; $EG='</B></SPAN>';}
echo "| {$G}{$channel}{$EG} | {$G}{$status}{$EG} | {$G}{$campaign}{$EG} | {$G}{$number_dialed}{$EG} | {$G}{$start_time}{$EG} | {$G}{$call_time_MS}{$EG} |\n";
$i++;
}
echo "+---------------------+--------+--------------+--------------------+----------+---------+\n";
echo " {$i} " . _QXZ("calls being placed on server") . " {$server_ip}\n\n";
echo " <SPAN class=\"green\"><B> </SPAN> - " . _QXZ("LIVE CALL WAITING") . "</B>\n";
# echo " <SPAN class=\"red\"><B> </SPAN> - Over 5 minutes on hold</B>\n";
} else {
echo "***************************************************************************************\n";
echo "***************************************************************************************\n";
echo "******************************* " . _QXZ("NO LIVE CALLS WAITING", 21) . " *********************************\n";
echo "***************************************************************************************\n";
echo "***************************************************************************************\n";
}
?>
</PRE>
</TD></TR></TABLE>
</BODY></HTML>
示例15: submit_form
function submit_form()
{
var appointment_hourFORM = document.getElementById('appointment_hour');
var appointment_hourVALUE = appointment_hourFORM[appointment_hourFORM.selectedIndex].text;
var appointment_minFORM = document.getElementById('appointment_min');
var appointment_minVALUE = appointment_minFORM[appointment_minFORM.selectedIndex].text;
document.vsn.appointment_time.value = appointment_hourVALUE + ":" + appointment_minVALUE + ":00";
document.vsn.submit();
}
</SCRIPT>
<input type=button value="<?php
echo _QXZ("SUBMIT");
?>
" name=smt id=smt onClick="submit_form()">
</TD>
</TR>
</TABLE>
</FORM>
</CENTER>
</B></FONT>
</TD>
</TR>
</TABLE>