diff --git a/ajax.php b/ajax.php index bb745515e..2d7d9fbd0 100644 --- a/ajax.php +++ b/ajax.php @@ -4,7 +4,7 @@ } $cmd = $_GET["command"]; $cmd = preg_replace("#[^a-zA-Z_]#","",$cmd); - $path = DIRNAME(__FILE__); + $path = __DIR__; $cmdpath = "$path/ajax/$cmd.php"; if(!file_exists($cmdpath)) { die(json_encode(array("success"=>false,"code"=>-1,"msg"=>"Invalid command!"))); diff --git a/ajax/add_bulk_complete_marker.php b/ajax/add_bulk_complete_marker.php index fe2702ec9..565f61c41 100644 --- a/ajax/add_bulk_complete_marker.php +++ b/ajax/add_bulk_complete_marker.php @@ -1,5 +1,5 @@ query($query); // or die(mysql_error()); if ($result) { - + } else { echo json_encode(array("success"=>false, "msg"=>$mysqli->error())); rollback(); exit(0); } - + if ($i != count($markerList) - 1) { $query = "insert into " . $map_prefix . "user_completed_marker ( user_id , marker_id , complete_date , visible - ) values "; + ) values "; } } } diff --git a/ajax/add_complete_marker.php b/ajax/add_complete_marker.php index 54443c1fb..73b0db469 100644 --- a/ajax/add_complete_marker.php +++ b/ajax/add_complete_marker.php @@ -1,5 +1,5 @@ error); return; } - + $res = array(); while($row = $result->fetch_assoc()) { $res[] = $row; diff --git a/ajax/get_container_name.php b/ajax/get_container_name.php index fdb34b5ec..e417f01ed 100644 --- a/ajax/get_container_name.php +++ b/ajax/get_container_name.php @@ -1,5 +1,5 @@