Changeset 73 for trunk/www/Application/View/Server.php
- Timestamp:
- Aug 23, 2009, 7:02:12 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/www/Application/View/Server.php
r71 r73 74 74 function ShowListOnRow($Row) 75 75 { 76 $Row['NetworkPortRealmd'] = '<a href=" realmlist.php?Id='.$Row['Id'].'">'.$Row['NetworkPortRealmd'].'</a>';76 $Row['NetworkPortRealmd'] = '<a href="?Module=Server&Action=RealmList&Id='.$Row['Id'].'">'.$Row['NetworkPortRealmd'].'</a>'; 77 77 if($Row['Homepage'] != '') $Row['Name'] = '<a href="'.$Row['Homepage'].'">'.$Row['Name'].'</a>'; 78 78 unset($Row['Homepage']); … … 313 313 return($Output); 314 314 } 315 316 function RealmListFile() 317 { 318 if(array_key_exists('Id', $_GET)) 319 { 320 Header('Content-Type: text/plain'); 321 Header('Content-Disposition: attachment; filename="realmlist.wtf"'); 322 $Server = new Server($this->Database, $_GET['Id']); 323 $Output = array( 324 'set realmlist '.$this->Config['Web']['Host'].':'.$Server->Server['NetworkPortRealmd'], 325 'set patchlist '.$this->Config['Web']['Host'].':'.$Server->Server['NetworkPortRealmd'], 326 'set portal eu', 327 ); 328 echo(implode("\n", $Output)); 329 } else echo('Musíte zadat Id serveru'); 330 } 331 332 function PatchList() 333 { 334 Header('Content-type: text/plain'); 335 if(array_key_exists('Id', $_GET)) 336 { 337 $Server = new Server($this->Database, $_GET['Id'] * 1); 338 echo($Server->GetPatchList()); 339 } else echo('Zadané id serveru nenalezeno.'); 340 } 341 342 function XMLExport() 343 { 344 Header('Content-Type: application/xml'); 345 346 $Output = '<?xml version="1.0" encoding="utf-8"?>'; 347 if(array_key_exists('File', $_GET)) 348 { 349 Header('Content-Disposition: filename="'.$_GET['File'].'.xml"'); 350 if($_GET['File'] == 'ServerList') 351 { 352 $Output .= '<serverlist version="1.0">'; 353 $DbResult = $this->Database->query('SELECT * FROM Server'); 354 while($Server = $DbResult->fetch_assoc()) 355 { 356 $Output .= '<server>'. 357 '<name>'.$Server['Name'].'</name>'. 358 //'<playermaxcount>'.$Server['PlayerMaxCount'].'</playermaxcount>'. 359 //'<playeronlinecount>'.$Server['PlayerOnlineCount'].'</playeronlinecount>'. 360 '<homepage>'.$Server['Homepage'].'</homepage>'. 361 '</server>'; 362 } 363 $Output .= '</serverlist>'; 364 } 365 } else $Output .= '<document/>'; 366 $Html = new Html(); 367 if($this->Config['Web']['FormatHTML'] == true) echo($Html->FormatOutput($Output)); 368 else echo($Output); 369 } 315 370 } 316 371
Note:
See TracChangeset
for help on using the changeset viewer.