You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
22 lines
641 B
22 lines
641 B
<?php
|
|
require_once('../ajax_asm.php');
|
|
if( $CUser->Data['id'] > 1 ){
|
|
if( $CUser->Data['access'] > 5 ){
|
|
//Check Time Sync
|
|
$MTS = time();
|
|
$CTS = intval( $_POST['CTS'] );
|
|
// If difference more then 2 minutes
|
|
if( abs( $MTS-$CTS ) > 120 ){
|
|
//Push Kernel Command -> Sync Time
|
|
//$QS = "INSERT INTO `command_bus`(`target_id`,`cmd`,`status`,`parameter`) VALUES(1,252,0,'{$CTS}')";
|
|
//$DATABASE->Query( $QS, false );
|
|
// Logout user to perform time sync
|
|
//echo "{'sessionIsValid': false }";
|
|
//exit();
|
|
};
|
|
};
|
|
echo "{'sessionIsValid': true }";
|
|
} else {
|
|
echo "{'sessionIsValid': false }";
|
|
};
|
|
?>
|