Changeset 695 for trunk/pages
- Timestamp:
- Mar 20, 2010, 9:10:18 PM (15 years ago)
- Location:
- trunk/pages
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/pages/jak-zacit.php
r693 r695 24 24 <li>Můžete se zaregistrovat do diskuzního fóra serveru <a href="'.$html->Link('/forum/').'">zde</a>.</li> 25 25 <li>Ve hře se můžete připojit příkazem /join world do společného textového chat kanálu.</li> 26 <li>Prozkoumejte webové stránky serveru a sledujte <a href=" rss.php?category=articles">nejnovější informace</a> přes RSS čtečku.</li>26 <li>Prozkoumejte webové stránky serveru a sledujte <a href="'.$html->Link('/rss.php?category=articles').'">nejnovější informace</a> přes RSS čtečku.</li> 27 27 </ul> 28 28 <br /> -
trunk/pages/spolek.php
r691 r695 29 29 $time = mktime($time_stp[0], $time_stp[1], $time_stp[2], $date[1], $date[2], $date[0]); 30 30 $human_date = date('d.m.Y H:i:s', $time); 31 echo('<a href="'.$html->Link('/spolky/').'"><- Zpět na výpis</a><br />');31 //echo('<a href="'.$html->Link('/spolky/').'"><- Zpět na výpis</a><br />'); 32 32 echo('<table class="BaseTable"> 33 33 <tr> -
trunk/pages/spolky.php
r691 r695 33 33 } 34 34 35 $Realm = new Realm($System, $_COOKIE['RealmIndex']); 36 $db2 = $Realm->CharactersDatabase; 37 38 if(count($QueryItems) > 3) 39 { 40 $GuildName = $QueryItems[3]; 41 $DbResult = $db2->query('SELECT guildid FROM guild WHERE '.$System->SQLURLName('Name').'="'.$GuildName.'"'); 42 $DbRow = $DbResult->fetch_assoc(); 43 $_GET['id'] = $DbRow['guildid']; 44 include('spolek.php'); 45 } else 46 { 35 47 echo('<h3 class="PageTitle">Seznam spolků</h3>'); 36 48 echo($server->RealmSelection()); … … 46 58 </tr>'); 47 59 48 $Realm = new Realm($System, $_COOKIE['RealmIndex']);49 $db2 = $Realm->CharactersDatabase;50 60 51 $sql = $db2->query('SELECT `guild`.name, `guild`.guildid, FROM_UNIXTIME(`guild`.`createdate`) AS `createdate`, COUNT(`guild_member`.`guildid`) AS member_count ,`leader`.`race` IN (1, 3, 4, 7, 11) AS fraction , `leader`.`guid` AS leader FROM `guild` JOIN `guild_member` ON `guild_member`.`guildid` = `guild`.`guildid` JOIN `characters` AS `memebers` ON `memebers`.`guid`= `guild_member`.`guid` JOIN `characters` AS `leader` ON `leader`.`guid`= `guild`.`leaderguid` GROUP BY guild.name ORDER BY '.$order_by.' '.$order_dir.';');61 $sql = $db2->query('SELECT `guild`.name, '.$System->SQLURLName('`guild`.name').' AS URLName, `guild`.guildid, FROM_UNIXTIME(`guild`.`createdate`) AS `createdate`, COUNT(`guild_member`.`guildid`) AS member_count ,`leader`.`race` IN (1, 3, 4, 7, 11) AS fraction , `leader`.`guid` AS leader FROM `guild` JOIN `guild_member` ON `guild_member`.`guildid` = `guild`.`guildid` JOIN `characters` AS `memebers` ON `memebers`.`guid`= `guild_member`.`guid` JOIN `characters` AS `leader` ON `leader`.`guid`= `guild`.`leaderguid` GROUP BY guild.name ORDER BY '.$order_by.' '.$order_dir.';'); 52 62 while($row = $sql->fetch_assoc()) 53 63 { … … 64 74 echo('<tr> 65 75 <td align="center">'.FrakceImg($row['fraction']).'</td> 66 <td align="center"><a href="'.$html->Link( '/spolek/?id='.$row['guildid']).'">'.$row['name'].'</a></td>76 <td align="center"><a href="'.$html->Link($row['URLName'].'/').'">'.$row['name'].'</a></td> 67 77 <td align="center">'.$row['member_count'].'</td> 68 78 <td align="center">'.$online_mem['online_mem'].'</td> … … 73 83 } 74 84 echo('</table>'); 85 } 75 86 76 87 ?> -
trunk/pages/svety.php
r693 r695 1 1 <?php 2 2 3 function RealmList() 4 { 5 global $System, $html; 6 3 7 if(array_key_exists('Server', $_GET)) 4 8 { … … 31 35 '</tr>'; 32 36 33 $DbResult2 = $System->Database->query('SELECT * FROM Realm WHERE Logon='.$Server->Id.' AND Enabled=1 ORDER BY Name');37 $DbResult2 = $System->Database->query('SELECT *, '.$System->SQLURLName('Name').' AS URLName FROM Realm WHERE Logon='.$Server->Id.' AND Enabled=1 ORDER BY Name'); 34 38 while($DbRow = $DbResult2->fetch_assoc()) 35 39 { 36 40 $Realm = new Realm($System, $DbRow['Id']); 37 $Output .= '<tr><td><a href="'.$html->Link('/ online-hraci/?RealmIndex='.$Realm->Id).'">'.$Realm->Data['Name'].'</a></td><td>'.$Realm->Data['Rate'].'</td><td>'.$Realm->Data['Type'].'</td><td>'.$Server->OnlineStateImage($Realm->Data['Online']).'</td><td>'.$Realm->OnlineCharactersCount().' / '.$Realm->Data['MaxOnlinePlayers'].' / '.$Realm->CharacterCount().'</td></tr>';41 $Output .= '<tr><td><a href="'.$html->Link('/svety/'.$DbRow['URLName'].'/').'">'.$Realm->Data['Name'].'</a></td><td>'.$Realm->Data['Rate'].'</td><td>'.$Realm->Data['Type'].'</td><td>'.$Server->OnlineStateImage($Realm->Data['Online']).'</td><td>'.$Realm->OnlineCharactersCount().' / '.$Realm->Data['MaxOnlinePlayers'].' / '.$Realm->CharacterCount().'</td></tr>'; 38 42 $Output .= '<tr><td colspan="5">'.$Realm->Data['Description'].'</td></tr>'; 39 43 //if(array_key_exists($Index + 1, $Config['Mangos']['RealmList'])) … … 44 48 echo($Output); 45 49 } 50 } 51 52 function RealmInfo() 53 { 54 global $System; 55 56 $DbResult = $System->Database->query('SELECT * FROM Realm WHERE Id='.$_COOKIE['RealmIndex']); 57 $Realm = $DbResult->fetch_assoc(); 58 echo('<h2 align="center">'.$Realm['Name'].'</h2>'); 59 echo($Realm['Information']); 60 } 61 62 if(count($QueryItems) > 1) 63 { 64 $RealmName = $QueryItems[1]; 65 $DbResult = $System->Database->query('SELECT Id FROM Realm WHERE '.$System->SQLURLName('Name').'="'.$RealmName.'"'); 66 $DbRow = $DbResult->fetch_assoc(); 67 $_COOKIE['RealmIndex'] = $DbRow['Id']; 68 69 if(count($QueryItems) > 2) 70 { 71 if($QueryItems[2] == 'online-hraci') include('online-hraci.php'); 72 else if($QueryItems[2] == 'prikazy') include('prikazy.php'); 73 else if($QueryItems[2] == 'akce') include('akce.php'); 74 else if($QueryItems[2] == 'arena') include('arena.php'); 75 else if($QueryItems[2] == 'nej-hraci') include('nej-hraci.php'); 76 else if($QueryItems[2] == 'mapa') include('mapa.php'); 77 else if($QueryItems[2] == 'spolek') include('spolek.php'); 78 else if($QueryItems[2] == 'spolky') include('spolky.php'); 79 else RealmInfo(); 80 } else RealmInfo(); 81 } else RealmList(); 46 82 47 83 ?>
Note:
See TracChangeset
for help on using the changeset viewer.