release 1.2.3
This commit is contained in:
@@ -111,10 +111,12 @@ function calc_serverstats($ts3,$mysqlcon,$lang,$dbname,$slowmode,$timezone,$serv
|
||||
arsort($country_array);
|
||||
$country_counter = 0;
|
||||
$country_nation_other = 0;
|
||||
$country_nation_name_1 = 0;
|
||||
$country_nation_name_2 = 0;
|
||||
$country_nation_name_3 = 0;
|
||||
$country_nation_name_4 = 0;
|
||||
$country_nation_name_5 = 0;
|
||||
$country_nation_1 = 0;
|
||||
$country_nation_2 = 0;
|
||||
$country_nation_3 = 0;
|
||||
$country_nation_4 = 0;
|
||||
|
||||
@@ -8,7 +8,7 @@ function calc_user($ts3,$mysqlcon,$lang,$dbname,$slowmode,$timezone,$update,$gro
|
||||
$getversion = $getversion->fetchAll();
|
||||
$updatetime = $nowtime - 43200;
|
||||
if ($getversion[0]['timestamp'] < $updatetime) {
|
||||
$newversion=get_data('http://ts-n.net/ranksystem/'.$upchannel,$currvers,$ts);
|
||||
$newversion=get_data('https://ts-n.net/ranksystem/'.$upchannel,$currvers,$ts);
|
||||
if($mysqlcon->exec("UPDATE $dbname.job_check SET timestamp='$nowtime' WHERE job_name='get_version'") === false) {
|
||||
enter_logfile($logpath,$timezone,2,"calc_user -2:".print_r($mysqlcon->errorInfo(), true));
|
||||
}
|
||||
@@ -101,6 +101,16 @@ function calc_user($ts3,$mysqlcon,$lang,$dbname,$slowmode,$timezone,$update,$gro
|
||||
krsort($grouptime);
|
||||
$sumentries = 0;
|
||||
$nextupforinsert = key($grouptime) - 1;
|
||||
|
||||
if(!isset($dbgroups)) {
|
||||
if(($dbgroups = $mysqlcon->query("SELECT sgid,sgidname FROM $dbname.groups")) === false) {
|
||||
enter_logfile($logpath,$timezone,2,"calc_user 8.1:".print_r($mysqlcon->errorInfo(), true));
|
||||
} else {
|
||||
$dbgroups = $dbgroups->fetchAll(PDO::FETCH_ASSOC);
|
||||
}
|
||||
}
|
||||
|
||||
print_r($dbgroups);
|
||||
|
||||
foreach ($allclients as $client) {
|
||||
$sumentries++;
|
||||
@@ -164,7 +174,7 @@ function calc_user($ts3,$mysqlcon,$lang,$dbname,$slowmode,$timezone,$update,$gro
|
||||
try {
|
||||
$ts3->serverGroupClientDel($boost['group'], $cldbid);
|
||||
$boosttime = 0;
|
||||
enter_logfile($logpath,$timezone,5,sprintf($lang['sgrprm'], $sqlhis[$uid]['grpid'], $name, $uid, $cldbid));
|
||||
enter_logfile($logpath,$timezone,5,sprintf($lang['sgrprm'], $dbgroups[$sqlhis[$uid]['grpid']]['sgidname'], $sqlhis[$uid]['grpid'], $name, $uid, $cldbid));
|
||||
}
|
||||
catch (Exception $e) {
|
||||
enter_logfile($logpath,$timezone,2,"calc_user 8:".sprintf($lang['sgrprerr'], $name, $uid, $cldbid));
|
||||
@@ -213,7 +223,7 @@ function calc_user($ts3,$mysqlcon,$lang,$dbname,$slowmode,$timezone,$update,$gro
|
||||
check_shutdown($timezone,$logpath); usleep($slowmode);
|
||||
try {
|
||||
$ts3->serverGroupClientDel($sqlhis[$uid]['grpid'], $cldbid);
|
||||
enter_logfile($logpath,$timezone,5,sprintf($lang['sgrprm'], $sqlhis[$uid]['grpid'], $name, $uid, $cldbid));
|
||||
enter_logfile($logpath,$timezone,5,sprintf($lang['sgrprm'], $dbgroups[$sqlhis[$uid]['grpid']]['sgidname'], $sqlhis[$uid]['grpid'], $name, $uid, $cldbid));
|
||||
}
|
||||
catch (Exception $e) {
|
||||
enter_logfile($logpath,$timezone,2,"calc_user 9:".sprintf($lang['sgrprerr'], $name, $uid, $cldbid));
|
||||
@@ -224,7 +234,7 @@ function calc_user($ts3,$mysqlcon,$lang,$dbname,$slowmode,$timezone,$update,$gro
|
||||
try {
|
||||
$ts3->serverGroupClientAdd($groupid, $cldbid);
|
||||
$grpsince = $nowtime;
|
||||
enter_logfile($logpath,$timezone,5,sprintf($lang['sgrpadd'], $groupid, $name, $uid, $cldbid));
|
||||
enter_logfile($logpath,$timezone,5,sprintf($lang['sgrpadd'], $dbgroups[$groupid]['sgidname'], $groupid, $name, $uid, $cldbid));
|
||||
}
|
||||
catch (Exception $e) {
|
||||
enter_logfile($logpath,$timezone,2,"calc_user 10:".sprintf($lang['sgrprerr'], $name, $uid, $cldbid));
|
||||
@@ -238,7 +248,7 @@ function calc_user($ts3,$mysqlcon,$lang,$dbname,$slowmode,$timezone,$update,$gro
|
||||
$mins = $dtF->diff($dtT)->format('%i');
|
||||
$secs = $dtF->diff($dtT)->format('%s');
|
||||
try {
|
||||
$ts3->clientGetByUid($uid)->message(sprintf($rankupmsg, $days, $hours, $mins, $secs));
|
||||
$ts3->clientGetByUid($uid)->message(sprintf($rankupmsg, $days, $hours, $mins, $secs, $dbgroups[$groupid]['sgidname'], $client['client_nickname']));
|
||||
} catch (Exception $e) {
|
||||
enter_logfile($logpath,$timezone,2,"calc_user 12:".sprintf($lang['sgrprerr'], $name, $uid, $cldbid));
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?PHP
|
||||
function check_db($mysqlcon,$lang,$dbname,$timezone,$currvers,$logpath) {
|
||||
$newversion = '1.2.2';
|
||||
$newversion = '1.2.3';
|
||||
enter_logfile($logpath,$timezone,5,"Check Ranksystem database for updates.");
|
||||
|
||||
function set_new_version($mysqlcon,$dbname,$timezone,$newversion,$logpath) {
|
||||
@@ -16,8 +16,8 @@ function check_db($mysqlcon,$lang,$dbname,$timezone,$currvers,$logpath) {
|
||||
}
|
||||
|
||||
function check_chmod($timezone,$logpath,$lang) {
|
||||
if(substr(sprintf('%o', fileperms(substr(__DIR__,0,-4).'icons/')), -3, 1)!='7') {
|
||||
enter_logfile($logpath,$timezone,2,sprintf($lang['isntwichm'],'icons'));
|
||||
if(substr(sprintf('%o', fileperms(substr(__DIR__,0,-4).'tsicons/')), -3, 1)!='7') {
|
||||
enter_logfile($logpath,$timezone,2,sprintf($lang['isntwichm'],'tsicons'));
|
||||
}
|
||||
if(substr(sprintf('%o', fileperms($logpath)), -3, 1)!='7') {
|
||||
enter_logfile($logpath,$timezone,2,sprintf($lang['isntwichm'],'logs'));
|
||||
@@ -98,7 +98,7 @@ function check_db($mysqlcon,$lang,$dbname,$timezone,$currvers,$logpath) {
|
||||
enter_logfile($logpath,$timezone,4,"Unnecessary file, please delete it from your webserver: other/style.css.php");
|
||||
}
|
||||
}
|
||||
if(is_file(substr(__DIR__,0,-4).'other/search.php')) {
|
||||
if(is_file(substr(__DIR__,0,-4).'other/search.php')) {
|
||||
if(!unlink(substr(__DIR__,0,-4).'other/search.php')) {
|
||||
enter_logfile($logpath,$timezone,4,"Unnecessary file, please delete it from your webserver: other/search.php");
|
||||
}
|
||||
@@ -108,6 +108,21 @@ function check_db($mysqlcon,$lang,$dbname,$timezone,$currvers,$logpath) {
|
||||
enter_logfile($logpath,$timezone,4,"Unnecessary file, please delete it from your webserver: server-news");
|
||||
}
|
||||
}
|
||||
if(is_dir(substr(__DIR__,0,-4).'icons/')) {
|
||||
if(!rmdir(substr(__DIR__,0,-4).'icons/')) {
|
||||
enter_logfile($logpath,$timezone,4,"Unnecessary folder, please delete it from your webserver: icons/");
|
||||
}
|
||||
}
|
||||
if(is_file(substr(__DIR__,0,-4).'libs/combined_stats.css')) {
|
||||
if(!unlink(substr(__DIR__,0,-4).'libs/combined_stats.css')) {
|
||||
enter_logfile($logpath,$timezone,4,"Unnecessary file, please delete it from your webserver: libs/combined_stats.css");
|
||||
}
|
||||
}
|
||||
if(is_file(substr(__DIR__,0,-4).'libs/combined_stats.js')) {
|
||||
if(!unlink(substr(__DIR__,0,-4).'libs/combined_stats.js')) {
|
||||
enter_logfile($logpath,$timezone,4,"Unnecessary file, please delete it from your webserver: libs/combined_stats.js");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function check_writable($timezone,$logpath) {
|
||||
@@ -421,6 +436,21 @@ function check_db($mysqlcon,$lang,$dbname,$timezone,$currvers,$logpath) {
|
||||
enter_logfile($logpath,$timezone,4," [1.2.2] Created table addon_assign_groups successfully.");
|
||||
}
|
||||
}
|
||||
if(version_compare($currvers, '1.2.2', '<=')) {
|
||||
if($mysqlcon->exec("DELETE FROM $dbname.groups") === false) { } else {
|
||||
enter_logfile($logpath,$timezone,4," [1.2.3] Cleaned table groups successfully. (cause new icon folder tsicons - redownload)");
|
||||
}
|
||||
if($mysqlcon->exec("ALTER TABLE $dbname.config MODIFY COLUMN tsvoice smallint(5) UNSIGNED NOT NULL default '0'") === false) { } else {
|
||||
enter_logfile($logpath,$timezone,4," [1.2.3] Adjusted table config successfully.");
|
||||
}
|
||||
if($mysqlcon->exec("CREATE INDEX snapshot_timestamp ON $dbname.user_snapshot (timestamp)") === false) { } else {
|
||||
enter_logfile($logpath,$timezone,4," [1.2.3] Recreated index on table user_snapshot successfully.");
|
||||
}
|
||||
|
||||
if($mysqlcon->exec("CREATE INDEX serverusage_timestamp ON $dbname.server_usage (timestamp)") === false) { } else {
|
||||
enter_logfile($logpath,$timezone,4," [1.2.3] Recreated index on table server_usage successfully.");
|
||||
}
|
||||
}
|
||||
$currvers = set_new_version($mysqlcon,$dbname,$timezone,$newversion,$logpath);
|
||||
old_files($timezone,$logpath);
|
||||
check_chmod($timezone,$logpath,$lang);
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
<?PHP
|
||||
function get_avatars($ts3,$mysqlcon,$lang,$dbname,$slowmode,$timezone,$logpath,$avatar_delay) {
|
||||
$count = 0;
|
||||
|
||||
try {
|
||||
check_shutdown($timezone,$logpath); usleep($slowmode);
|
||||
$tsfilelist = $ts3->channelFileList($cid="0", $cpw="", $path="/");
|
||||
@@ -33,7 +31,6 @@ function get_avatars($ts3,$mysqlcon,$lang,$dbname,$slowmode,$timezone,$logpath,$
|
||||
if(file_put_contents($avatarfilepath, $tsfile) === false) {
|
||||
enter_logfile($logpath,$timezone,2,"Error while writing out the avatar. Please check the permission for the folder 'avatars'");
|
||||
}
|
||||
$count++;
|
||||
}
|
||||
catch (Exception $e) {
|
||||
enter_logfile($logpath,$timezone,2,"get_avatars 2:".$e->getCode().': '."Error while downloading avatar: ".$e->getMessage());
|
||||
|
||||
@@ -5,9 +5,9 @@ function handle_messages(TeamSpeak3_Adapter_ServerQuery_Event $event, TeamSpeak3
|
||||
$uuid = $event["invokeruid"];
|
||||
|
||||
|
||||
if(strstr($event["msg"], 'nextup') && $nextupinfo != 0) {
|
||||
if((strstr($event["msg"], '!nextup') || strstr($event["msg"], '!next')) && $nextupinfo != 0) {
|
||||
//enter_logfile($logpath,$timezone,6,"Client ".$event["invokername"]." (".$event["invokeruid"].") sent textmessage: ".$event["msg"]);
|
||||
if(($dbuserdata = $mysqlcon->query("SELECT count,nextup,idle,except FROM $dbname.user WHERE uuid='$uuid'")) === false) {
|
||||
if(($dbuserdata = $mysqlcon->query("SELECT count,nextup,idle,except,name FROM $dbname.user WHERE uuid='$uuid'")) === false) {
|
||||
enter_logfile($logpath,$timezone,2,"handle_messages 1:".print_r($mysqlcon->errorInfo(), true));
|
||||
}
|
||||
$user = $dbuserdata->fetchAll(PDO::FETCH_ASSOC);
|
||||
@@ -35,24 +35,25 @@ function handle_messages(TeamSpeak3_Adapter_ServerQuery_Event $event, TeamSpeak3
|
||||
$hours = $dtF->diff($dtT)->format('%h');
|
||||
$mins = $dtF->diff($dtT)->format('%i');
|
||||
$secs = $dtF->diff($dtT)->format('%s');
|
||||
$name = $user[0]['name'];
|
||||
$grpcount++;
|
||||
if ($nextup > 0 && $nextup < $time || $grpcount == $countgrp && $nextup <= 0) {
|
||||
check_shutdown($timezone,$logpath); usleep($slowmode);
|
||||
if ($grpcount == $countgrp && $nextup <= 0) {
|
||||
try {
|
||||
$host->serverGetSelected()->clientGetByUid($event["invokeruid"])->message(sprintf($nextupinfomsg2, $days, $hours, $mins, $secs, $sqlhisgroup[$groupid]));
|
||||
$host->serverGetSelected()->clientGetByUid($event["invokeruid"])->message(sprintf($nextupinfomsg2, $days, $hours, $mins, $secs, $sqlhisgroup[$groupid], $name));
|
||||
} catch (Exception $e) {
|
||||
enter_logfile($logpath,$timezone,2,"handle_messages 3:".$e->getCode().': '.$e->getMessage());
|
||||
}
|
||||
} elseif ($user[0]['except'] == 2 || $user[0]['except'] == 3) {
|
||||
try {
|
||||
$host->serverGetSelected()->clientGetByUid($event["invokeruid"])->message(sprintf($nextupinfomsg3, $days, $hours, $mins, $secs, $sqlhisgroup[$groupid]));
|
||||
$host->serverGetSelected()->clientGetByUid($event["invokeruid"])->message(sprintf($nextupinfomsg3, $days, $hours, $mins, $secs, $sqlhisgroup[$groupid], $name));
|
||||
} catch (Exception $e) {
|
||||
enter_logfile($logpath,$timezone,2,"handle_messages 4:".$e->getCode().': '.$e->getMessage());
|
||||
}
|
||||
} else {
|
||||
try {
|
||||
$host->serverGetSelected()->clientGetByUid($event["invokeruid"])->message(sprintf($nextupinfomsg1, $days, $hours, $mins, $secs, $sqlhisgroup[$groupid]));
|
||||
$host->serverGetSelected()->clientGetByUid($event["invokeruid"])->message(sprintf($nextupinfomsg1, $days, $hours, $mins, $secs, $sqlhisgroup[$groupid], $name));
|
||||
} catch (Exception $e) {
|
||||
enter_logfile($logpath,$timezone,2,"handle_messages 5:".$e->getCode().': '.$e->getMessage());
|
||||
}
|
||||
@@ -64,7 +65,7 @@ function handle_messages(TeamSpeak3_Adapter_ServerQuery_Event $event, TeamSpeak3
|
||||
}
|
||||
}
|
||||
|
||||
if(strstr($event["msg"], 'version')) {
|
||||
if(strstr($event["msg"], '!version')) {
|
||||
if(version_compare(substr($newversion, 0, 5), substr($currvers, 0, 5), '>') && $newversion != '') {
|
||||
try {
|
||||
$host->serverGetSelected()->clientGetByUid($event["invokeruid"])->message(sprintf($lang['upmsg'], $currvers, $newversion));
|
||||
@@ -80,7 +81,7 @@ function handle_messages(TeamSpeak3_Adapter_ServerQuery_Event $event, TeamSpeak3
|
||||
}
|
||||
}
|
||||
|
||||
if(strstr($event["msg"], 'help') || strstr($event["msg"], 'info') || strstr($event["msg"], 'commands')) {
|
||||
if(strstr($event["msg"], '!help') || strstr($event["msg"], '!info') || strstr($event["msg"], '!commands')) {
|
||||
try {
|
||||
$host->serverGetSelected()->clientGetByUid($event["invokeruid"])->message($lang['msg0002']);
|
||||
} catch (Exception $e) {
|
||||
@@ -88,7 +89,7 @@ function handle_messages(TeamSpeak3_Adapter_ServerQuery_Event $event, TeamSpeak3
|
||||
}
|
||||
}
|
||||
|
||||
if((strstr($event["msg"], 'shutdown') || strstr($event["msg"], 'quit') || strstr($event["msg"], 'stop')) && $event["invokeruid"] == $adminuuid) {
|
||||
if((strstr($event["msg"], '!shutdown') || strstr($event["msg"], '!quit') || strstr($event["msg"], '!stop')) && $event["invokeruid"] == $adminuuid) {
|
||||
enter_logfile($logpath,$timezone,5,sprintf($lang['msg0004'], $event["invokername"], $event["invokeruid"]));
|
||||
$path = substr(__DIR__, 0, -4);
|
||||
try {
|
||||
@@ -97,7 +98,7 @@ function handle_messages(TeamSpeak3_Adapter_ServerQuery_Event $event, TeamSpeak3
|
||||
enter_logfile($logpath,$timezone,2,"handle_messages 9:".$e->getCode().': '.$e->getMessage());
|
||||
}
|
||||
exec($phpcommand." ".$path."worker.php stop");
|
||||
} elseif (strstr($event["msg"], 'shutdown') || strstr($event["msg"], 'exit')) {
|
||||
} elseif (strstr($event["msg"], '!shutdown') || strstr($event["msg"], '!quit') || strstr($event["msg"], '!stop')) {
|
||||
try {
|
||||
$host->serverGetSelected()->clientGetByUid($event["invokeruid"])->message($lang['msg0003']);
|
||||
} catch (Exception $e) {
|
||||
@@ -105,7 +106,7 @@ function handle_messages(TeamSpeak3_Adapter_ServerQuery_Event $event, TeamSpeak3
|
||||
}
|
||||
}
|
||||
|
||||
if((strstr($event["msg"], 'restart') || strstr($event["msg"], 'reboot')) && $event["invokeruid"] == $adminuuid) {
|
||||
if((strstr($event["msg"], '!restart') || strstr($event["msg"], '!reboot')) && $event["invokeruid"] == $adminuuid) {
|
||||
enter_logfile($logpath,$timezone,5,sprintf($lang['msg0007'], $event["invokername"], $event["invokeruid"]));
|
||||
$path = substr(__DIR__, 0, -4);
|
||||
try {
|
||||
@@ -118,7 +119,7 @@ function handle_messages(TeamSpeak3_Adapter_ServerQuery_Event $event, TeamSpeak3
|
||||
} else {
|
||||
exec($phpcommand." ".$path."worker.php restart > /dev/null 2>/dev/null &");
|
||||
}
|
||||
} elseif (strstr($event["msg"], 'shutdown') || strstr($event["msg"], 'exit')) {
|
||||
} elseif (strstr($event["msg"], '!restart') || strstr($event["msg"], '!reboot')) {
|
||||
try {
|
||||
$host->serverGetSelected()->clientGetByUid($event["invokeruid"])->message($lang['msg0003']);
|
||||
} catch (Exception $e) {
|
||||
@@ -126,6 +127,22 @@ function handle_messages(TeamSpeak3_Adapter_ServerQuery_Event $event, TeamSpeak3
|
||||
}
|
||||
}
|
||||
|
||||
if((strstr($event["msg"], '!checkupdate') || strstr($event["msg"], '!update')) && $event["invokeruid"] == $adminuuid) {
|
||||
if($mysqlcon->exec("UPDATE $dbname.job_check SET timestamp='0' WHERE job_name IN ('check_update','get_version')") === false) {
|
||||
enter_logfile($logpath,$timezone,4,"handle_messages 13:".print_r($mysqlcon->errorInfo(), true));
|
||||
}
|
||||
try {
|
||||
$host->serverGetSelected()->clientGetByUid($event["invokeruid"])->message($lang['msg0008']);
|
||||
} catch (Exception $e) {
|
||||
enter_logfile($logpath,$timezone,2,"handle_messages 14:".$e->getCode().': '.$e->getMessage());
|
||||
}
|
||||
} elseif (strstr($event["msg"], '!checkupdate') || strstr($event["msg"], '!update')) {
|
||||
try {
|
||||
$host->serverGetSelected()->clientGetByUid($event["invokeruid"])->message($lang['msg0003']);
|
||||
} catch (Exception $e) {
|
||||
enter_logfile($logpath,$timezone,2,"handle_messages 15:".$e->getCode().': '.$e->getMessage());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
?>
|
||||
@@ -50,8 +50,8 @@ function update_groups($ts3,$mysqlcon,$lang,$dbname,$slowmode,$timezone,$serveri
|
||||
check_shutdown($timezone,$logpath); usleep($slowmode);
|
||||
enter_logfile($logpath,$timezone,5,"Download new ServerIcon");
|
||||
$sIconFile = $ts3->iconDownload();
|
||||
if(file_put_contents(substr(dirname(__FILE__),0,-4) . "icons/servericon.png", $sIconFile) === false) {
|
||||
enter_logfile($logpath,$timezone,2,"Error while writing out the servericon. Please check the permission for the folder 'icons'");
|
||||
if(file_put_contents(substr(dirname(__FILE__),0,-4) . "tsicons/servericon.png", $sIconFile) === false) {
|
||||
enter_logfile($logpath,$timezone,2,"Error while writing out the servericon. Please check the permission for the folder 'tsicons'");
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
enter_logfile($logpath,$timezone,2,"update_groups 4:".$e->getCode().': '."Error while downloading servericon: ".$e->getMessage());
|
||||
@@ -95,8 +95,8 @@ function update_groups($ts3,$mysqlcon,$lang,$dbname,$slowmode,$timezone,$serveri
|
||||
} catch (Exception $e) {
|
||||
enter_logfile($logpath,$timezone,2,"update_groups 5:".$e->getCode().': '."Error while downloading servergroupicon: ".$e->getMessage());
|
||||
}
|
||||
if(file_put_contents(substr(dirname(__FILE__),0,-4) . "icons/" . $sgid . ".png", $iconfile) === false) {
|
||||
enter_logfile($logpath,$timezone,2,"Error while writing out the servergroup icon. Please check the permission for the folder 'icons'");
|
||||
if(file_put_contents(substr(dirname(__FILE__),0,-4) . "tsicons/" . $sgid . ".png", $iconfile) === false) {
|
||||
enter_logfile($logpath,$timezone,2,"Error while writing out the servergroup icon. Please check the permission for the folder 'tsicons'");
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
enter_logfile($logpath,$timezone,2,"update_groups 6:".$e->getCode().': '."Error while downloading servergroup icon: ".$e->getMessage());
|
||||
|
||||
@@ -117,16 +117,10 @@ function update_rs($mysqlcon,$lang,$dbname,$logpath,$timezone,$newversion,$phpco
|
||||
|
||||
if (substr(php_uname(), 0, 7) == "Windows") {
|
||||
exec("start ".$phpcommand." ".$path."worker.php restart");
|
||||
exit;
|
||||
} else {
|
||||
exec($phpcommand." ".$path."worker.php restart > /dev/null 2>/dev/null &");
|
||||
}
|
||||
|
||||
if (substr(php_uname(), 0, 7) == "Windows") {
|
||||
$WshShell = new COM("WScript.Shell");
|
||||
$oExec = $WshShell->Run("cmd /C php ".substr(__DIR__,0,-4)."\worker.php stop", 0, false);
|
||||
} else {
|
||||
exec("php ".substr(__DIR__,0,-5)."/worker.php stop");
|
||||
check_shutdown($timezone,$logpath);
|
||||
exit;
|
||||
}
|
||||
} else {
|
||||
enter_logfile($logpath,$timezone,1," Files updated with at least one error. Please check the log!\n",$norotate);
|
||||
|
||||
Reference in New Issue
Block a user