Some replacements

+Replaced all $GLOBALS['link'] with $database->dblink
-Removed Templates/links.tpl from build.php (it's already in
Templates/menu.tpl)
This commit is contained in:
iopietro
2018-04-08 19:55:28 +02:00
parent 6ea4430372
commit 9e44c1cd6d
58 changed files with 382 additions and 380 deletions
+1 -1
View File
@@ -138,7 +138,7 @@ $tocoor = $database->getCoor($enforce['vref']);
}
if ($enforce['hero']>0){
$qh = "SELECT unit FROM ".TB_PREFIX."hero WHERE uid = ".(int) $to['owner']." AND dead = 0";
$resulth = mysqli_query($GLOBALS['link'],$qh);
$resulth = mysqli_query($database->dblink,$qh);
$hero_f=mysqli_fetch_array($resulth);
$hero_unit=$hero_f['unit'];
$speeds[] = $GLOBALS['u'.$hero_unit]['speed'];
+1 -1
View File
@@ -139,7 +139,7 @@ $tocoor = $database->getCoor($enforce['vref']);
}
if ($enforce['hero']>0){
$qh = "SELECT unit FROM ".TB_PREFIX."hero WHERE uid = ".(int) $to['owner']." AND dead = 0";
$resulth = mysqli_query($GLOBALS['link'],$qh);
$resulth = mysqli_query($database->dblink,$qh);
$hero_f=mysqli_fetch_array($resulth);
$hero_unit=$hero_f['unit'];
$speeds[] = $GLOBALS['u'.$hero_unit]['speed'];
+1 -1
View File
@@ -138,7 +138,7 @@ $tocoor = $database->getCoor($enforce['vref']);
}
if ($enforce['hero']>0){
$qh = "SELECT unit FROM ".TB_PREFIX."hero WHERE uid = ".(int) $to['owner']." AND dead = 0";
$resulth = mysqli_query($GLOBALS['link'],$qh);
$resulth = mysqli_query($database->dblink,$qh);
$hero_f=mysqli_fetch_array($resulth);
$hero_unit=$hero_f['unit'];
$speeds[] = $GLOBALS['u'.$hero_unit]['speed'];
+1 -1
View File
@@ -139,7 +139,7 @@ $tocoor = $database->getCoor($enforce['vref']);
}
if ($enforce['hero']>0){
$qh = "SELECT unit FROM ".TB_PREFIX."hero WHERE uid = ".(int) $to['owner']." AND dead = 0";
$resulth = mysqli_query($GLOBALS['link'],$qh);
$resulth = mysqli_query($database->dblink,$qh);
$hero_f=mysqli_fetch_array($resulth);
$hero_unit=$hero_f['unit'];
$speeds[] = $GLOBALS['u'.$hero_unit]['speed'];
+1 -1
View File
@@ -138,7 +138,7 @@ $tocoor = $database->getCoor($enforce['vref']);
}
if ($enforce['hero']>0){
$qh = "SELECT unit FROM ".TB_PREFIX."hero WHERE uid = ".(int) $to['owner']." AND dead = 0";
$resulth = mysqli_query($GLOBALS['link'],$qh);
$resulth = mysqli_query($database->dblink,$qh);
$hero_f=mysqli_fetch_array($resulth);
$hero_unit=$hero_f['unit'];
$speeds[] = $GLOBALS['u'.$hero_unit]['speed'];
+1 -1
View File
@@ -7,7 +7,7 @@
$sql = "SELECT id, towref, t1, t2, t3, t4, t5, t6, t7, t8, t9, t10 FROM ".TB_PREFIX."raidlist WHERE lid = ".$database->escape((int) $lid)." order by id asc";
$array = $database->query_return($sql);
foreach($array as $row){
$sql1 = mysqli_fetch_array(mysqli_query($GLOBALS['link'],"SELECT * FROM ".TB_PREFIX."units WHERE vref = ".(int) $getFLData['wref']));
$sql1 = mysqli_fetch_array(mysqli_query($database->dblink,"SELECT * FROM ".TB_PREFIX."units WHERE vref = ".(int) $getFLData['wref']));
$sid = $row['id'];
$wref = $row['towref'];
$t1 = $row['t1'];$t2 = $row['t2'];$t3 = $row['t3'];$t4 = $row['t4'];$t5 = $row['t5'];