$RemoveIP = ValidVar($_GP['RemoveIP']); if (!ValidArr($RemoveIp)) { $RemoveIp = false; } $MyIP = $_SERVER['REMOTE_ADDR']; ///////////////////////////////////////////// ///////// call any process functions if (!$nsUser->DEMO) { if ($NewIp && ValidIp($NewIp)) { AddNewIp($NewIp, $NewIpDescr); } if ($NewIp && ValidIpTempl($NewIp)) { AddNewIpTempl($NewIp, $NewIpDescr); } if ($RemoveIP) { RemoveIp($RemoveIP); } } ///////////////////////////////////////////// ///////// display section here $IpList = array(); $Query = "SELECT * FROM " . PFX . "_tracker_ip WHERE IGNORED = '1' ORDER BY IP ASC"; $Sql = new Query($Query); $Sql->ReadSkinConfig(); while ($Row = $Sql->Row()) { $Row->_STYLE = $Sql->_STYLE; $Row->TEMPLATE = false; $IpList[] = $Row; } $Query = "SELECT * FROM " . PFX . "_tracker_ip_ignore ORDER BY TEMPLATE ASC"; $Sql = new Query($Query);
$SubMenu[0]['Link'] = getURL("my_tracker", "Mode=visitor_grps"); $MenuSection = "my_tracker"; $ProgPath[0]['Name'] = $Lang['MyTracker']; $ProgPath[0]['Url'] = getUrl("my_tracker", "", "admin"); if (ValidVar($NewIp) && !ValidIpTempl($NewIp)) { $Logs->Err($Lang['InvalidIp']); $NewIp = false; } ///////////////////////////////////////////// ///////// call any process functions if (!$nsUser->DEMO) { if (ValidId($EditId) && $NewIp) { AddIp($NewIp, $EditId); } if (ValidId($EditId) && ValidId($DeleteIp)) { RemoveIp($DeleteIp, $EditId); } if (ValidArr($EditArr) && $EditId == "new") { CreateNewGrp($EditArr); } if (ValidArr($EditArr) && ValidId($EditId)) { UpdateGrp($EditId, $EditArr); } } ///////////////////////////////////////////// ///////// display section here if ($EditId == "new") { if (!$EditArr) { $EditArr['Name'] = ""; $EditArr['Descr'] = ""; $EditArr['Wacth'] = 0;
<?php include 'functions.php'; $ip = $_SERVER['REMOTE_ADDR']; /*ip address of user */ $message = ""; /*message to be returned*/ /*Check if ip already associated with player in connections table*/ RemoveIp($ip); $message = '{"LOGGEDOUT" : true}'; echo $message;
$ProgPath[1]['Url'] = getUrl("visitor", "CpId={$CpId}&ViewId=" . $Visitor->ID, "admin"); } else { $ProgPath[1]['Name'] = $Lang['Visitor'] . " " . $Visitor->ID; $ProgPath[1]['Url'] = getUrl("visitor", "CpId={$CpId}&ViewId=" . $Visitor->ID, "admin"); } ///////////////////////////////////////////// ///////// call any process functions if (!$nsUser->DEMO) { if (ValidArr($EditArr)) { UpdateVisitor($VisId, $EditArr); } if (ValidId($Visitor->CLIENT_VIS_ID) && $NewIp) { AddIp($NewIp, $Visitor->CLIENT_VIS_ID); } if (ValidId($Visitor->CLIENT_VIS_ID) && ValidId($DeleteIp)) { RemoveIp($DeleteIp, $Visitor->CLIENT_VIS_ID); } } ///////////////////////////////////////////// ///////// display section here $GrpIpArr = array(); $IpTemplArr = array(); if (ValidId($Visitor->CLIENT_VIS_ID)) { $Query = "SELECT ID, IP FROM " . PFX . "_tracker_client_visitor_ip WHERE CLIENT_VISITOR_ID=" . $Visitor->CLIENT_VIS_ID; $Sql = new Query($Query); $Sql->ReadSkinConfig(); while ($Row = $Sql->Row()) { $Row->_STYLE = $Sql->_STYLE; $IpArr[] = $Row; if (strpos($Row->IP, "*") === false) { $GrpIpArr[] = "'" . $Row->IP . "'";