This is an old revision of the document!


PHP

<?php
header("Content-Type: text/plain");
 
$mystr = "My BusinessHours_5_1_60";
$myvar = (explode("_",$mystr));
//echo $myvar;
print_r (explode("_",$mystr));
//print_r $myvar;
echo "\n".$myvar[0];
echo "\n".$myvar[1];
echo "\n".$myvar[2];
echo "\n".$myvar[3];
echo "\n".$myvar[4];
 
//if empty($myMinAgentCount){$myMinAgentCount = '0';} else {$myMinAgentCount = $myvar[2];}
 
$myProactiveChatTimer = $myvar[1];
$myMinAgentCount = $myvar[2];
$myMaxQueueDepth = $myvar[3];
$myMaxWaitTime = $myvar[4];
 
if ((empty($myProactiveChatTimer))||(!is_numeric($myProactiveChatTimer))) {$myProactiveChatTimer = '0';}
if ((empty($myMinAgentCount))|| (!is_numeric($myMinAgentCount))) {$myMinAgentCount = '0';}
if ((empty($myMaxWaitTime))|| (!is_numeric($myMaxWaitTime))) {$myMaxWaitTime = '0';}
if ((empty($myMaxQueueDepth))||(!is_numeric($myMaxQueueDepth))) {$myMaxQueueDepth = '0';}
 
echo "\nmyProactiveChatTimer: ".$myProactiveChatTimer;
echo "\nmyMinAgentCount: ".$myMinAgentCount;
echo "\nmyMaxQueueDepth: ".$myMaxQueueDepth;
echo "\nmyMaxWaitTime: ".$myMaxWaitTime;
?>
<?php
echo 'Hello ' . htmlspecialchars($_GET["name"]) . '!';
$myname = htmlspecialchars($_GET["name"]);
echo "myname variable is: " . $myname;
?>
  • code/php/home.1568541141.txt.gz
  • Last modified: 2019/09/15 10:52
  • by gerardorourke