Example #1
0
<?php

namespace IngressPlanner;

error_reporting(E_ALL);
ini_set('error_log', 'php-error.log');
ini_set('log_errors', true);
require 'htmlHelper.php';
$html = new Helpers\HtmlHelper();
require 'basics.php';
echo json_encode(\saveAgent($_REQUEST));
Example #2
0
         case "AgentRelations":
             echo saveAgentRelations();
             break;
         case "AgentTeams":
             echo saveAgentTeams();
             break;
         default:
             echo "Table to change not specified.";
     }
     break;
 case "save":
     // Save changes to a record
     switch ($table) {
         case "Agent":
             $agentid = preg_replace('[^0-9]', '', array_key_exists("agentid", $_REQUEST) ? $_REQUEST["agentid"] : "");
             echo saveAgent($agentid);
             break;
         case "AgentName":
             $agentnameid = preg_replace('[^0-9]', '', array_key_exists("agentnamesid", $_REQUEST) ? $_REQUEST["agentnamesid"] : "");
             echo saveAgentName($agentnameid);
             break;
         case "AgentNumberPattern":
             $agentnumberpatternid = preg_replace('[^0-9]', '', array_key_exists("agentnumberpatternid", $_REQUEST) ? $_REQUEST["agentnumberpatternid"] : "");
             echo saveAgentNumberPattern($agentnumberpatternid);
             break;
         case "AgentLinks":
             $agentlinksid = preg_replace('[^0-9]', '', array_key_exists("agentlinksid", $_REQUEST) ? $_REQUEST["agentlinksid"] : "");
             echo saveAgentLinks($agentlinksid);
             break;
         case "AgentRelations":
             $agentrelid = preg_replace('[^0-9]', '', array_key_exists("agentrelationsid", $_REQUEST) ? $_REQUEST["agentrelationsid"] : "");