Changeset 232
- Timestamp:
- Jul 2, 2009, 9:41:51 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/includes/global_function.php
r226 r232 125 125 } else 126 126 { 127 return(false); 127 if(isset($_SERVER['REMOTE_ADDR'])) 128 { 129 return(true); 130 } else { 131 return(false); 132 } 128 133 } 129 134 } … … 281 286 function GetBuildNumber($Version) 282 287 { 283 global $Database ;288 global $Database,$BuildNumbers; 284 289 285 $sql = 'SELECT BuildNumber FROM `wow_client_version` WHERE Version = "'.$Version.'"'; 286 $BuildNumber = mysql_fetch_assoc($Database->SQLCommand($sql)); 287 return($BuildNumber['BuildNumber']); 290 if (isset($VersionsWOW[$BuildNumber]) == false) 291 { 292 $sql = 'SELECT BuildNumber FROM `wow_client_version` WHERE Version = "'.$Version.'"'; 293 $DbRow = mysql_fetch_assoc($Database->SQLCommand($sql)); 294 $BuildNumbers[$Version] = $DbRow['BuildNumber']; 295 } 296 return($BuildNumbers[$Version]); 288 297 } 289 298 … … 302 311 function GetDBCColumns($Version,$DBCFileName) 303 312 { 304 global $Database,$BuildNumbers; 305 if (isset($BuildNumbers[$Version]) == false) 306 { 307 $sql = 'SELECT DBCColumns_'.$DBCFileName.' as DBCColumns FROM `wow_client_version` WHERE Version = "'.$Version.'"'; 308 $DbRow = mysql_fetch_assoc($Database->SQLCommand($sql)); 309 $BuildNumbers[$Version] = $DbRow['DBCColumns']; 310 } 311 return($BuildNumbers[$Version]); 313 global $Database; 314 $sql = 'SELECT DBCColumns_'.$DBCFileName.' as DBCColumns FROM `wow_client_version` WHERE Version = "'.$Version.'"'; 315 $DbRow = mysql_fetch_assoc($Database->SQLCommand($sql)); 316 return($DbRow['DBCColumns']); 312 317 } 313 318
Note:
See TracChangeset
for help on using the changeset viewer.