mirror of
https://github.com/Shadowss/TravianZ.git
synced 2026-06-28 00:24:23 +00:00
fix: logging works, tech log link added to Admin
This commit is contained in:
@@ -21,7 +21,7 @@ class Logging {
|
||||
$log .= "access village $ref";
|
||||
break;
|
||||
}
|
||||
$q = "Insert into ".TB_PREFIX."illegal_log values (0,$uid,'$log')";
|
||||
$q = "Insert into ".TB_PREFIX."illegal_log SET user = $uid, log = '$log'";
|
||||
$database->query($q);
|
||||
}
|
||||
}
|
||||
@@ -30,7 +30,7 @@ class Logging {
|
||||
global $database;
|
||||
list($id,$ip) = $database->escape_input((int) $id,$ip);
|
||||
if(LOG_LOGIN) {
|
||||
$q = "Insert into ".TB_PREFIX."login_log values (0,$id,'$ip')";
|
||||
$q = "Insert into ".TB_PREFIX."login_log SET uid = $id, ip = '".$_SERVER['REMOTE_ADDR']."'";
|
||||
$database->query($q);
|
||||
}
|
||||
}
|
||||
@@ -45,8 +45,8 @@ class Logging {
|
||||
else {
|
||||
$log = "Start Upgrade of ";
|
||||
}
|
||||
$log .= $building." at level ".$level;
|
||||
$q = "Insert into ".TB_PREFIX."build_log values (0,$wid,'$log')";
|
||||
$log .= $building." to level ".$level;
|
||||
$q = "Insert into ".TB_PREFIX."build_log SET wid = $wid, log = '$log'";
|
||||
$database->query($q);
|
||||
}
|
||||
}
|
||||
@@ -56,7 +56,7 @@ class Logging {
|
||||
list($wid,$tech,$level) = $database->escape_input((int) $wid,$tech,$level);
|
||||
if(LOG_TECH) {
|
||||
$log = "Upgrading of tech ".$tech." to level ".$level;
|
||||
$q = "Insert into ".TB_PREFIX."tech_log values (0,$wid,'$log')";
|
||||
$q = "Insert into ".TB_PREFIX."tech_log SET wid = $wid, log = '$log'";
|
||||
$database->query($q);
|
||||
}
|
||||
}
|
||||
@@ -85,7 +85,7 @@ class Logging {
|
||||
else if($type == 2) {
|
||||
$log = "Traded resource between ".$wid." and ".$data[0]." market ref is ".$data[1];
|
||||
}
|
||||
$q = "Insert into ".TB_PREFIX."market_log values (0,$wid,'$log')";
|
||||
$q = "Insert into ".TB_PREFIX."market_log SET wid = $wid, log = '$log'";
|
||||
$database->query($q);
|
||||
}
|
||||
}
|
||||
@@ -107,8 +107,8 @@ class Logging {
|
||||
//fwrite($fh,"\n".date("Y-m-d H:i:s")." : ".$time.",".$uid.",".$debug_info."\n");
|
||||
//fclose($fh);
|
||||
|
||||
$q = "INSERT INTO ".TB_PREFIX."debug_log (time,uid,debug_info) VALUES ($time,$uid,'$debug_info')";
|
||||
$database->query($q);
|
||||
//$q = "INSERT INTO ".TB_PREFIX."debug_log (time,uid,debug_info) VALUES ($time,$uid,'$debug_info')";
|
||||
//$database->query($q);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user