From 0e6b45d605058ae4d5a08e34154c61344e9ae80e Mon Sep 17 00:00:00 2001 From: sempoi Date: Sat, 8 Mar 2014 15:46:15 +0800 Subject: [PATCH 01/18] Update constant_format.tpl --- GameEngine/Admin/Mods/constant_format.tpl | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/GameEngine/Admin/Mods/constant_format.tpl b/GameEngine/Admin/Mods/constant_format.tpl index ed929175..04b8750d 100644 --- a/GameEngine/Admin/Mods/constant_format.tpl +++ b/GameEngine/Admin/Mods/constant_format.tpl @@ -16,6 +16,7 @@ ////////////////////////////////// // (E_ALL ^ E_NOTICE) = enabled // (0) = disabled +define("ERROR_REPORT","%ERRORREPORT%"); %ERROR% ////////////////////////////////// @@ -295,4 +296,4 @@ $requse = 0; ## ## ################################################################################# -?> \ No newline at end of file +?> From 6ba2da8da7d1663220ba86e4f5441c0406b16a29 Mon Sep 17 00:00:00 2001 From: sempoi Date: Sat, 8 Mar 2014 15:47:47 +0800 Subject: [PATCH 02/18] Update constant_format.tpl --- install/data/constant_format.tpl | 1 + 1 file changed, 1 insertion(+) diff --git a/install/data/constant_format.tpl b/install/data/constant_format.tpl index 430e6a18..942588b7 100644 --- a/install/data/constant_format.tpl +++ b/install/data/constant_format.tpl @@ -16,6 +16,7 @@ ////////////////////////////////// // (E_ALL ^ E_NOTICE) = enabled // (0) = disabled +define("ERROR_REPORT","%ERRORREPORT%"); %ERROR% ////////////////////////////////// From 157e209a85d7ab74eb8b8f89d4c2093207bb71bf Mon Sep 17 00:00:00 2001 From: sempoi Date: Sat, 8 Mar 2014 15:50:53 +0800 Subject: [PATCH 03/18] Update process.php --- install/process.php | 1 + 1 file changed, 1 insertion(+) diff --git a/install/process.php b/install/process.php index 705f3532..21031210 100644 --- a/install/process.php +++ b/install/process.php @@ -90,6 +90,7 @@ class Process { $text = preg_replace("'%BOX2%'", $_POST['box2'], $text); $text = preg_replace("'%BOX3%'", $_POST['box3'], $text); $text = preg_replace("'%VILLAGE_EXPAND%'", $_POST['village_expand'], $text); + $text = preg_replace("'%ERRORREPORT%'", $_POST['error'], $text); $text = preg_replace("'%ERROR%'", $_POST['error'], $text); $text = preg_replace("'%GP_LOCATE%'", $_POST['gp_locate'], $text); $text = preg_replace("'%PLUS_TIME%'", $_POST['plus_time'], $text); From b0d88601af5db93598f57e38829a209d403af4e4 Mon Sep 17 00:00:00 2001 From: sempoi Date: Sat, 8 Mar 2014 15:54:46 +0800 Subject: [PATCH 04/18] Update editAdminInfo.tpl --- Admin/Templates/editAdminInfo.tpl | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/Admin/Templates/editAdminInfo.tpl b/Admin/Templates/editAdminInfo.tpl index 98f931bd..8fc06083 100644 --- a/Admin/Templates/editAdminInfo.tpl +++ b/Admin/Templates/editAdminInfo.tpl @@ -41,14 +41,6 @@ if($_SESSION['access'] < 9) die(ACCESS_DENIED_ADMIN); - - Error Reporting - - -
@@ -57,4 +49,4 @@ if($_SESSION['access'] < 9) die(ACCESS_DENIED_ADMIN); - \ No newline at end of file + From bd7ae0d74cd3f5b1b6e32f8154aac783b118baf3 Mon Sep 17 00:00:00 2001 From: sempoi Date: Sat, 8 Mar 2014 15:55:47 +0800 Subject: [PATCH 05/18] Update editExtraSet.tpl --- Admin/Templates/editExtraSet.tpl | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/Admin/Templates/editExtraSet.tpl b/Admin/Templates/editExtraSet.tpl index 8e177e18..a12d1b05 100644 --- a/Admin/Templates/editExtraSet.tpl +++ b/Admin/Templates/editExtraSet.tpl @@ -37,14 +37,7 @@ if($_SESSION['access'] < 9) die(ACCESS_DENIED_ADMIN); Max Number of Mails 30 - - Error Reporting - - - +
@@ -53,4 +46,4 @@ if($_SESSION['access'] < 9) die(ACCESS_DENIED_ADMIN); - \ No newline at end of file + From 3562807643ce7bbaf569125c5686c6d19d05a819 Mon Sep 17 00:00:00 2001 From: sempoi Date: Sat, 8 Mar 2014 15:56:39 +0800 Subject: [PATCH 06/18] Update editLogSet.tpl --- Admin/Templates/editLogSet.tpl | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/Admin/Templates/editLogSet.tpl b/Admin/Templates/editLogSet.tpl index d9a02e98..5fd06c9b 100644 --- a/Admin/Templates/editLogSet.tpl +++ b/Admin/Templates/editLogSet.tpl @@ -97,13 +97,7 @@ if($_SESSION['access'] < 9) die(ACCESS_DENIED_ADMIN); - Error Reporting - - - +
@@ -112,4 +106,4 @@ if($_SESSION['access'] < 9) die(ACCESS_DENIED_ADMIN); - \ No newline at end of file + From c7173aa084cde24a77adcfc53c00df75d327b733 Mon Sep 17 00:00:00 2001 From: sempoi Date: Sat, 8 Mar 2014 15:57:43 +0800 Subject: [PATCH 07/18] Update editNewsboxSet.tpl --- Admin/Templates/editNewsboxSet.tpl | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/Admin/Templates/editNewsboxSet.tpl b/Admin/Templates/editNewsboxSet.tpl index f5d523cc..2d4d31e2 100644 --- a/Admin/Templates/editNewsboxSet.tpl +++ b/Admin/Templates/editNewsboxSet.tpl @@ -52,13 +52,7 @@ if($_SESSION['access'] < 9) die(ACCESS_DENIED_ADMIN); - Error Reporting - - - +
@@ -67,4 +61,4 @@ if($_SESSION['access'] < 9) die(ACCESS_DENIED_ADMIN); - \ No newline at end of file + From d731218b332f58a46f558edeca1458d2846490b0 Mon Sep 17 00:00:00 2001 From: sempoi Date: Sat, 8 Mar 2014 16:04:34 +0800 Subject: [PATCH 08/18] Update config.tpl --- Admin/Templates/config.tpl | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Admin/Templates/config.tpl b/Admin/Templates/config.tpl index 4851e7b4..1777abfe 100644 --- a/Admin/Templates/config.tpl +++ b/Admin/Templates/config.tpl @@ -153,6 +153,11 @@ if($_SESSION['access'] < 9) die(ACCESS_DENIED_ADMIN); Graphic Pack Enabled"; } else { echo "Disabled"; } ?> + + Error Reporting + + + @@ -342,4 +347,4 @@ function define_array( $array, $keys = NULL ) } } //define_array($array); -?> \ No newline at end of file +?> From c78d6109801a025614ba084e2843247422a680a1 Mon Sep 17 00:00:00 2001 From: sempoi Date: Sat, 8 Mar 2014 16:09:57 +0800 Subject: [PATCH 09/18] Update editAdminInfo.php --- GameEngine/Admin/Mods/editAdminInfo.php | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/GameEngine/Admin/Mods/editAdminInfo.php b/GameEngine/Admin/Mods/editAdminInfo.php index f71c570b..3534abdb 100644 --- a/GameEngine/Admin/Mods/editAdminInfo.php +++ b/GameEngine/Admin/Mods/editAdminInfo.php @@ -17,7 +17,7 @@ $id = $_POST['id']; $myFile = "../../config.php"; $fh = fopen($myFile, 'w') or die("


Can't open file: GameEngine\config.php"); - + $ERRORREPORT=ERROR_REPORT; $T4=(T4_COMING==false)? "false":"true"; $GP_ENABLE=(GP_ENABLE==false)? "false":"true"; $QUEST=(QUEST==false)? "false":"true"; @@ -41,7 +41,8 @@ $fh = fopen($myFile, 'w') or die("


Can't open file: GameEngine\con $LIMIT_MAILBOX=(LIMIT_MAILBOX==false)? "false":"true"; $text = file_get_contents("constant_format.tpl"); - $text = preg_replace("'%ERROR%'", $_POST['error'], $text); + $text = preg_replace("'%ERRORREPORT%'", $ERRORREPORT, $text); + $text = preg_replace("'%ERROR%'", $ERRORREPORT, $text); $text = preg_replace("'%SERVERNAME%'", SERVER_NAME, $text); $text = preg_replace("'%STIMEZONE%'", TIMEZONE, $text); $text = preg_replace("'%STARTTIME%'", COMMENCE, $text); @@ -111,4 +112,4 @@ $database->query("Insert into ".TB_PREFIX."admin_log values (0,".$id.",'Changed header("Location: ../../../Admin/admin.php?p=config"); -?> \ No newline at end of file +?> From 70809fa64193d53d2e6f20602f209e57d79cf949 Mon Sep 17 00:00:00 2001 From: sempoi Date: Sat, 8 Mar 2014 16:13:20 +0800 Subject: [PATCH 10/18] Update editNewsboxSet.php --- GameEngine/Admin/Mods/editNewsboxSet.php | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/GameEngine/Admin/Mods/editNewsboxSet.php b/GameEngine/Admin/Mods/editNewsboxSet.php index db2e35b5..b7dc9a71 100644 --- a/GameEngine/Admin/Mods/editNewsboxSet.php +++ b/GameEngine/Admin/Mods/editNewsboxSet.php @@ -17,7 +17,7 @@ $id = $_POST['id']; $myFile = "../../config.php"; $fh = fopen($myFile, 'w') or die("


Can't open file: GameEngine\config.php"); - + $ERRORREPORT=ERROR_REPORT; $T4=(T4_COMING==false)? "false":"true"; $GP_ENABLE=(GP_ENABLE==false)? "false":"true"; $QUEST=(QUEST==false)? "false":"true"; @@ -41,7 +41,8 @@ $fh = fopen($myFile, 'w') or die("


Can't open file: GameEngine\con $INCLUDE_ADMIN=(INCLUDE_ADMIN==false)? "false":"true"; $text = file_get_contents("constant_format.tpl"); - $text = preg_replace("'%ERROR%'", $_POST['error'], $text); + $text = preg_replace("'%ERRORREPORT%'", $ERRORREPORT, $text); + $text = preg_replace("'%ERROR%'", $ERRORREPORT, $text); $text = preg_replace("'%SERVERNAME%'", SERVER_NAME, $text); $text = preg_replace("'%STIMEZONE%'", TIMEZONE, $text); $text = preg_replace("'%STARTTIME%'", COMMENCE, $text); @@ -113,4 +114,4 @@ $database->query("Insert into ".TB_PREFIX."admin_log values (0,".$id.",'Changed header("Location: ../../../Admin/admin.php?p=config"); -?> \ No newline at end of file +?> From 9689ccb2c1c7e68e8ecc74ef59c691a7b3839aac Mon Sep 17 00:00:00 2001 From: sempoi Date: Sat, 8 Mar 2014 16:14:23 +0800 Subject: [PATCH 11/18] Update editExtraSet.php --- GameEngine/Admin/Mods/editExtraSet.php | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/GameEngine/Admin/Mods/editExtraSet.php b/GameEngine/Admin/Mods/editExtraSet.php index 15a23d6f..554e7831 100644 --- a/GameEngine/Admin/Mods/editExtraSet.php +++ b/GameEngine/Admin/Mods/editExtraSet.php @@ -17,7 +17,7 @@ $id = $_POST['id']; $myFile = "../../config.php"; $fh = fopen($myFile, 'w') or die("


Can't open file: GameEngine\config.php"); - + $ERRORREPORT=ERROR_REPORT; $T4=(T4_COMING==false)? "false":"true"; $GP_ENABLE=(GP_ENABLE==false)? "false":"true"; $QUEST=(QUEST==false)? "false":"true"; @@ -41,7 +41,8 @@ $fh = fopen($myFile, 'w') or die("


Can't open file: GameEngine\con $INCLUDE_ADMIN=(INCLUDE_ADMIN==false)? "false":"true"; $text = file_get_contents("constant_format.tpl"); - $text = preg_replace("'%ERROR%'", $_POST['error'], $text); + $text = preg_replace("'%ERRORREPORT%'", $ERRORREPORT, $text); + $text = preg_replace("'%ERROR%'", $ERRORREPORT, $text); $text = preg_replace("'%SERVERNAME%'", SERVER_NAME, $text); $text = preg_replace("'%STIMEZONE%'", TIMEZONE, $text); $text = preg_replace("'%STARTTIME%'", COMMENCE, $text); @@ -111,4 +112,4 @@ $database->query("Insert into ".TB_PREFIX."admin_log values (0,".$id.",'Changed header("Location: ../../../Admin/admin.php?p=config"); -?> \ No newline at end of file +?> From 541853b7dd517b90bbc5fcc2f69b8f737aeb83fc Mon Sep 17 00:00:00 2001 From: sempoi Date: Sat, 8 Mar 2014 16:15:55 +0800 Subject: [PATCH 12/18] Update editLogSet.php --- GameEngine/Admin/Mods/editLogSet.php | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/GameEngine/Admin/Mods/editLogSet.php b/GameEngine/Admin/Mods/editLogSet.php index 0bc98f6b..87ae8ce5 100644 --- a/GameEngine/Admin/Mods/editLogSet.php +++ b/GameEngine/Admin/Mods/editLogSet.php @@ -17,7 +17,7 @@ $id = $_POST['id']; $myFile = "../../config.php"; $fh = fopen($myFile, 'w') or die("


Can't open file: GameEngine\config.php"); - + $ERRORREPORT=ERROR_REPORT; $T4=(T4_COMING==false)? "false":"true"; $GP_ENABLE=(GP_ENABLE==false)? "false":"true"; $QUEST=(QUEST==false)? "false":"true"; @@ -34,7 +34,8 @@ $fh = fopen($myFile, 'w') or die("


Can't open file: GameEngine\con $INCLUDE_ADMIN=(INCLUDE_ADMIN==false)? "false":"true"; $text = file_get_contents("constant_format.tpl"); - $text = preg_replace("'%ERROR%'", $_POST['error'], $text); + $text = preg_replace("'%ERRORREPORT%'", $ERRORREPORT, $text); + $text = preg_replace("'%ERROR%'", $ERRORREPORT, $text); $text = preg_replace("'%SERVERNAME%'", SERVER_NAME, $text); $text = preg_replace("'%STIMEZONE%'", TIMEZONE, $text); $text = preg_replace("'%STARTTIME%'", COMMENCE, $text); @@ -106,4 +107,4 @@ $database->query("Insert into ".TB_PREFIX."admin_log values (0,".$id.",'Changed header("Location: ../../../Admin/admin.php?p=config"); -?> \ No newline at end of file +?> From 0626ef20d5fe4c6f1034885807778a54a51c2a8a Mon Sep 17 00:00:00 2001 From: sempoi Date: Sat, 8 Mar 2014 16:17:15 +0800 Subject: [PATCH 13/18] Update editServerSet.php --- GameEngine/Admin/Mods/editServerSet.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/GameEngine/Admin/Mods/editServerSet.php b/GameEngine/Admin/Mods/editServerSet.php index c5cd6869..233351de 100644 --- a/GameEngine/Admin/Mods/editServerSet.php +++ b/GameEngine/Admin/Mods/editServerSet.php @@ -34,6 +34,7 @@ $fh = fopen($myFile, 'w') or die("


Can't open file: GameEngine\con $text = file_get_contents("constant_format.tpl"); + $text = preg_replace("'%ERRORREPORT%'", $_POST['error'], $text); $text = preg_replace("'%ERROR%'", $_POST['error'], $text); $text = preg_replace("'%SERVERNAME%'", $_POST['servername'], $text); $text = preg_replace("'%STIMEZONE%'", $_POST['tzone'], $text); @@ -104,4 +105,4 @@ $database->query("Insert into ".TB_PREFIX."admin_log values (0,".$id.",'Changed header("Location: ../../../Admin/admin.php?p=config"); -?> \ No newline at end of file +?> From 00aae86239dbfeeb3e1c99e6c70ec18e34990709 Mon Sep 17 00:00:00 2001 From: sempoi Date: Sat, 8 Mar 2014 19:45:49 +0800 Subject: [PATCH 14/18] Update editServerSet.tpl --- Admin/Templates/editServerSet.tpl | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Admin/Templates/editServerSet.tpl b/Admin/Templates/editServerSet.tpl index 0d67cc62..eb561f80 100644 --- a/Admin/Templates/editServerSet.tpl +++ b/Admin/Templates/editServerSet.tpl @@ -289,8 +289,9 @@ function refresh(tz) {
From c52ec838a3a85454c2886808c29202cb6fecfbd7 Mon Sep 17 00:00:00 2001 From: sempoi Date: Sat, 8 Mar 2014 20:21:20 +0800 Subject: [PATCH 15/18] Update mapscroll.tpl --- Templates/Ajax/mapscroll.tpl | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Templates/Ajax/mapscroll.tpl b/Templates/Ajax/mapscroll.tpl index 103bdb0c..e1f709eb 100644 --- a/Templates/Ajax/mapscroll.tpl +++ b/Templates/Ajax/mapscroll.tpl @@ -1,6 +1,7 @@ 0 and $neutralarray[0]['alli2']>0 and $do $image = ($donnees['map_occupied'] == 1 && $donnees['map_fieldtype'] > 0)?(($donnees['ville_user'] == $_SESSION['id_user'])? ($donnees['ville_pop']>=100? $donnees['ville_pop']>= 250?$donnees['ville_pop']>=500? 'b30': 'b20' :'b10' : 'b00') : (($targetalliance != 0)? ($friend==1? ($donnees['ville_pop']>=100? $donnees['ville_pop']>= 250?$donnees['ville_pop']>=500? 'b31': 'b21' :'b11' : 'b01') : ($war==1? ($donnees['ville_pop']>=100? $donnees['ville_pop']>= 250?$donnees['ville_pop']>=500? 'b32': 'b22' :'b12' : 'b02') : ($neutral==1? ($donnees['ville_pop']>=100? $donnees['ville_pop']>= 250?$donnees['ville_pop']>=500? 'b35': 'b25' :'b15' : 'b05') : ($targetalliance == $_SESSION['alliance_user']? ($donnees['ville_pop']>=100? $donnees['ville_pop']>= 250?$donnees['ville_pop']>=500? 'b33': 'b23' :'b13' : 'b03') : ($donnees['ville_pop']>=100? $donnees['ville_pop']>= 250?$donnees['ville_pop']>=500? 'b34': 'b24' :'b14' : 'b04'))))) : ($donnees['ville_pop']>=100? $donnees['ville_pop']>= 250?$donnees['ville_pop']>=500? 'b34': 'b24' :'b14' : 'b04'))) : $donnees['map_image']; -if($donnees['ville_user']==3 && $donnees['ville_name']=='WW Buildingplan'){ +if($donnees['ville_user']==3 && $donnees['ville_name']==PLANVILLAGE){ $image = "o99"; } //Javascript map info + $regcount=0; if($yrow!=7){ $map_js .= "[".$donnees['map_x'].",".$donnees['map_y'].",".$donnees['map_fieldtype'].",". ((!empty($donnees['map_oasis'])) ? $donnees['map_oasis'] : 0) .",\"d=".$donnees['map_id']."&c=".$generator->getMapCheck($donnees['map_id'])."\",\"".$image."\""; if($donnees['map_occupied']){ @@ -144,4 +146,4 @@ $image = "o99"; else {$map_js .= "]";} ++$i; } -echo '[['.$map_js.']'; \ No newline at end of file +echo '[['.$map_js.']'; From 37d4d564c9af7ea8224f34c2a740cb535bc8c993 Mon Sep 17 00:00:00 2001 From: sempoi Date: Sat, 8 Mar 2014 20:24:03 +0800 Subject: [PATCH 16/18] Update mapscroll2.tpl --- Templates/Ajax/mapscroll2.tpl | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Templates/Ajax/mapscroll2.tpl b/Templates/Ajax/mapscroll2.tpl index b2645b89..82347e85 100644 --- a/Templates/Ajax/mapscroll2.tpl +++ b/Templates/Ajax/mapscroll2.tpl @@ -1,6 +1,7 @@ 0 and $neutralarray[0]['alli2']>0 and $do $image = ($donnees['map_occupied'] == 1 && $donnees['map_fieldtype'] > 0)?(($donnees['ville_user'] == $_SESSION['id_user'])? ($donnees['ville_pop']>=100? $donnees['ville_pop']>= 250?$donnees['ville_pop']>=500? 'b30': 'b20' :'b10' : 'b00') : (($targetalliance != 0)? ($friend==1? ($donnees['ville_pop']>=100? $donnees['ville_pop']>= 250?$donnees['ville_pop']>=500? 'b31': 'b21' :'b11' : 'b01') : ($war==1? ($donnees['ville_pop']>=100? $donnees['ville_pop']>= 250?$donnees['ville_pop']>=500? 'b32': 'b22' :'b12' : 'b02') : ($neutral==1? ($donnees['ville_pop']>=100? $donnees['ville_pop']>= 250?$donnees['ville_pop']>=500? 'b35': 'b25' :'b15' : 'b05') : ($targetalliance == $_SESSION['alliance_user']? ($donnees['ville_pop']>=100? $donnees['ville_pop']>= 250?$donnees['ville_pop']>=500? 'b33': 'b23' :'b13' : 'b03') : ($donnees['ville_pop']>=100? $donnees['ville_pop']>= 250?$donnees['ville_pop']>=500? 'b34': 'b24' :'b14' : 'b04'))))) : ($donnees['ville_pop']>=100? $donnees['ville_pop']>= 250?$donnees['ville_pop']>=500? 'b34': 'b24' :'b14' : 'b04'))) : $donnees['map_image']; -if($donnees['ville_user']==3 && $donnees['ville_name']=='WW Buildingplan'){ +if($donnees['ville_user']==3 && $donnees['ville_name']==PLANVILLAGE){ $image = "o99"; } //Javascript map info + $regcount=0; if($yrow!=13){ $map_js .= "[".$donnees['map_x'].",".$donnees['map_y'].",".$donnees['map_fieldtype'].",". ((!empty($donnees['map_oasis'])) ? $donnees['map_oasis'] : 0) .",\"d=".$donnees['map_id']."&c=".$generator->getMapCheck($donnees['map_id'])."\",\"".$image."\""; if($donnees['map_occupied']){ @@ -161,4 +163,4 @@ $image = "o99"; else {$map_js .= "]";} ++$i; } -echo '[['.$map_js.']'; \ No newline at end of file +echo '[['.$map_js.']'; From 3cd3ac31a4a9b61673fa4da01bea388304acb05e Mon Sep 17 00:00:00 2001 From: sempoi Date: Sat, 8 Mar 2014 20:31:45 +0800 Subject: [PATCH 17/18] Update Session.php --- GameEngine/Session.php | 43 +++++++++++++++++++++--------------------- 1 file changed, 22 insertions(+), 21 deletions(-) diff --git a/GameEngine/Session.php b/GameEngine/Session.php index eecb98d5..dcb0f79c 100644 --- a/GameEngine/Session.php +++ b/GameEngine/Session.php @@ -17,30 +17,31 @@ mb_internal_encoding("UTF-8"); // Add for utf8 varriables. ## ## ################################################################################# -if(!file_exists('GameEngine/config.php') && !file_exists('../../GameEngine/config.php') && !file_exists('../../config.php')) { +if(file_exists('GameEngine/config.php') || file_exists('../../GameEngine/config.php') || file_exists('../../config.php') || file_exists('../GameEngine/config.php')) { +}else{ header("Location: install/"); } $script_name = ($_SERVER['REQUEST_URI'] == 'karte.php') ? 'karte' : $_SERVER['REQUEST_URI']; -include ("Battle.php"); -include ("Data/buidata.php"); -include ("Data/cp.php"); -include ("Data/cel.php"); -include ("Data/resdata.php"); -include ("Data/unitdata.php"); -include ("Data/hero_full.php"); -include ("config.php"); -include ("Database.php"); -include ("Mailer.php"); -include ("Form.php"); -include ("Generator.php"); -include ("Multisort.php"); -include ("Ranking.php"); -include ("Lang/" . LANG . ".php"); -include ("Logging.php"); -include ("Message.php"); -include ("Alliance.php"); -include ("Profile.php"); +include_once ("Battle.php"); +include_once ("Data/buidata.php"); +include_once ("Data/cp.php"); +include_once ("Data/cel.php"); +include_once ("Data/resdata.php"); +include_once ("Data/unitdata.php"); +include_once ("Data/hero_full.php"); +include_once ("config.php"); +include_once ("Database.php"); +include_once ("Mailer.php"); +include_once ("Form.php"); +include_once ("Generator.php"); +include_once ("Multisort.php"); +include_once ("Ranking.php"); +include_once ("Lang/" . LANG . ".php"); +include_once ("Logging.php"); +include_once ("Message.php"); +include_once ("Alliance.php"); +include_once ("Profile.php"); class Session { @@ -60,7 +61,7 @@ class Session { function Session() { $this->time = time(); - session_start(); + if (!isset($_SESSION)) session_start(); $this->logged_in = $this->checkLogin(); From 1fa26378cd1bb2ea95731890bf39df9eac3093bb Mon Sep 17 00:00:00 2001 From: sempoi Date: Sat, 8 Mar 2014 20:33:13 +0800 Subject: [PATCH 18/18] Update Database.php --- GameEngine/Database.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/GameEngine/Database.php b/GameEngine/Database.php index edf037ea..e576daef 100644 --- a/GameEngine/Database.php +++ b/GameEngine/Database.php @@ -9,7 +9,7 @@ ## ## ################################################################################# -include("config.php"); +include_once("config.php"); switch(DB_TYPE) { case 1: @@ -24,4 +24,4 @@ switch(DB_TYPE) { } ## Security include("Protection.php"); -?> \ No newline at end of file +?>
Error Reporting