Changeset 118 for db/hlavni.php
- Timestamp:
- Nov 4, 2007, 5:38:25 PM (17 years ago)
- Location:
- db
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
db
- Property svn:ignore
-
old new 1 1 config.php 2 navrh
-
- Property svn:ignore
-
db/hlavni.php
r109 r118 1 1 <?php 2 if($vlozeni_souboru == "OK"){ 2 if (!defined('IN_CODE')){ exit; }; 3 4 if( !empty($id) ){ 5 if( $id == "uvod" ){ $file = "uvod"; $nadpis = "Úvod"; } 6 elseif( $id == "login" ){ $file = "login"; $nadpis = "Přihlášení"; } 7 elseif( $id == "admin" ){ $file = "../admin/obsah"; $nadpis = "Administrace"; } 8 elseif( $id == "getchar" ){ $file = "getchar"; $nadpis = "Export postavy z databáze"; } 9 elseif( $id == "stats" ){ $file = "stats"; $nadpis = "Statistiky"; } 10 elseif( $id == "bugreport" ){ $file = "bug_report"; $nadpis = "Systém na opravu chyb"; } 11 elseif( $id == "sendbug" ){ $file = "bug_report"; $nadpis = "Systém na opravu chyb - nahlášení chyby"; } 12 elseif( $id == "races" ){ $file = "races"; $nadpis = "Rasy"; } 13 elseif( $id == "classes" ){ $file = "classes"; $nadpis = "Povolání"; } 14 elseif( $id == "chars" ){ $file = "chars"; $nadpis = "Postavy"; } 15 elseif( $id == "myacc" ){ $file = "myacc"; $nadpis = "Muj účet"; } 16 elseif( $id == "guild" ){ $file = "guild"; $nadpis = "Guildy"; } 17 elseif( $id == "items" ){ $file = "items"; $nadpis = "Hledání předmětů"; } 18 elseif( $id == "itemsets" ){ $file = "itemsets"; $nadpis = "Sady předmětů"; } 19 elseif( $id == "questy" ){ $file = "questy"; $nadpis = "Hledání úkolů"; } 20 elseif( $id == "qzone" ){ $file = "qzone"; $nadpis = "Úkoly podle oblastí"; } 21 elseif( $id == "qtrskill" ){ $file = "qtrskill"; $nadpis = "Úkoly na profese"; } 22 elseif( $id == "qspecial" ){ $file = "qspecial"; $nadpis = "Speciální úkoly"; } 23 elseif( $id == "creeps" ){ $file = "creeps"; $nadpis = "Hledání creepů"; } 24 elseif( $id == "czone" ){ $file = "czone"; $nadpis = "Creepové podle oblastí"; } 25 elseif( $id == "ctype" ){ $file = "ctype"; $nadpis = "Typy creepů"; } 26 elseif( $id == "crare" ){ $file = "crare"; $nadpis = "Jedineční creepové"; } 27 elseif( $id == "glevel" ){ $file = "glevel"; $nadpis = "Oblasti podle levelu"; } 28 elseif( $id == "gzone" ){ $file = "gzone"; $nadpis = "Plán světa"; } 29 elseif( $id == "spells" ){ $file = "spells"; $nadpis = "Hledání kouzel"; } 30 elseif( $id == "sclass" ){ $file = "sclass"; $nadpis = "Kouzla podle povolání"; } 31 elseif( $id == "talents" ){ $file = "talents"; $nadpis = "Prohlížení Talentů"; } 32 elseif( $id == "profes" ){ $file = "profes"; $nadpis = "Profese"; } 33 elseif( $id == "pteach" ){ $file = "pteach"; $nadpis = "Prohledávat učitele profesí"; } 34 elseif( $id == "navody" ){ $file = "guids"; $nadpis = "Návody ke hře"; } 35 elseif( $id == "eventy" ){ $file = "events"; $nadpis = "Dynamické evety ve hře"; } 36 else{ $file = "uvod"; $nadpis = "Úvod"; }; 37 38 $file = "./include/".$file.".php"; 39 } 40 elseif( !empty($quest) ){ 41 $quest_dotaz_nadpis = mysql_query("SELECT `Title` FROM `quest_template` WHERE `entry`='".$quest."' LIMIT 1"); 42 if( mysql_num_rows($quest_dotaz_nadpis) == "1" ) { $i = "0"; 43 $result = MySQL_Fetch_Array($quest_dotaz_nadpis); 44 $nadpis_quest = $result["Title"]; 45 } else{ $nadpis_quest = "Chyba !"; }; 46 $file = "./include/quest.php"; $nadpis = "Quest: ".$nadpis_quest; 47 if( !File_Exists($file) ){ $file = "./include/uvod.php"; }; 48 } 49 elseif( !empty($creature) ){ 50 $creature_dotaz_nadpis = mysql_query("SELECT `name`,`subname` FROM `creature_template` WHERE `entry`='".$creature."' LIMIT 1"); 51 if( mysql_num_rows($creature_dotaz_nadpis) == "1" ) { 52 $result = @MySQL_Fetch_Array($creature_dotaz_nadpis); 53 $nadpis_creature = $result["name"]; 54 $nadpis_creature .= (!empty($result['subname']))?" <".$result['subname'].">":""; 55 } else{ $nadpis_creature = "Chyba !"; }; 56 $file = "./include/creep.php"; $nadpis = "Creep: ".$nadpis_creature; 57 if( !File_Exists($file) ){ $file = "./include/uvod.php"; }; 58 } 59 elseif( !empty($item) ){ 60 $item_dotaz_nadpis = mysql_query("SELECT `name` FROM `item_template` WHERE `entry`='".$item."' LIMIT 1"); 61 if( mysql_num_rows($item_dotaz_nadpis) == 1 ) { 62 $result = @MySQL_Fetch_Array($item_dotaz_nadpis); 63 $nadpis_item = $result["name"]; 64 } else{ $nadpis_item = "Chyba !"; }; 65 $file = "./include/item.php"; $nadpis = "Item: ".$nadpis_item; 66 if( !File_Exists($file) ){ $file = "./include/uvod.php"; }; 67 } 68 elseif( !empty($guid) ){ 69 SwitchDB(3); // nastavení databáze na web 70 $guid_dotaz_nadpis = mysql_query("SELECT `nazev` FROM `data_navody` WHERE `id`='".$guid."' LIMIT 1"); 71 if( mysql_num_rows($guid_dotaz_nadpis) == 1 ) { 72 $result = @MySQL_Fetch_Array($guid_dotaz_nadpis); 73 $nadpis_guid = $result["nazev"]; 74 } else{ $nadpis_guid = "Chyba !"; }; 75 $file = "./include/guids.php"; $nadpis = "Návod: ".$nadpis_guid; 76 if( !File_Exists($file) ){ $file = "./include/uvod.php"; }; 77 } 78 else{ $file = "./include/uvod.php"; $nadpis = "Úvod"; }; 79 3 80 ?> 4 81 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> … … 12 89 <meta name="robots" content="all, follow"> 13 90 <link rel="stylesheet" type="text/css" href="css/css.php"> 14 <link rel="shortcut icon" href=" img/favicon.ico">91 <link rel="shortcut icon" href="./../favicon.ico"> 15 92 <script src="js/scripty.js" type="text/javascript"></script> 16 93 <title><?php echo $Config['DB_read']['DB_read']['Title']; ?></title> … … 19 96 <div id="center"><div id="hlavni"> 20 97 <div id="top"></div> 21 <div id="left">22 <ul id="hlavni_menu">98 <div id="left"> 99 <ul id="hlavni_menu"> 23 100 <?php echo GenerateMenu(); ?> 24 </ul><!-- hlavni_menu --> 25 </div><!-- left --> 101 </ul><!-- hlavni_menu --> 102 </div><!-- left --> 103 104 <div id="right"> 105 <h1><?php echo $nadpis; ?></h1> 106 <div id="text"> 26 107 27 <div id="right">28 108 <?php 29 require_once "obsah.php"; 109 if( !File_exists($file) ){ echo "<p>Chyba! Nebyl nalezen kořenový soubor.</p>"; }; 110 @require_once $file; 30 111 ?> 31 112 32 <div class="back">33 <div class="float"><?php echo $sql_select['strankovani']; ?></div>34 <a href="#top"><?php echo $text['navigation']['top']; ?></a> 35 <?php if( empty($_POST) ){ ?>36 <a href="<?php echo $_SERVER["HTTP_REFERER"]; ?>" id="back"><?php echo $text['navigation']['back']; ?></a>37 <?php }; ?>38 <script type="text/javascript">39 onload=document.getElementById('back').href="javascript:history.back();";40 </script>41 113 </div> 42 </div><!-- right --> 114 115 <div class="back"> 116 <div class="float"><?php echo $sql_select['strankovani']; ?></div> 117 <a href="#top"><?php echo $text['navigation']['top']; ?></a> 118 <?php if( empty($_POST) ){ ?> 119 <a href="<?php echo $_SERVER["HTTP_REFERER"]; ?>" id="back"><?php echo $text['navigation']['back']; ?></a> 120 <?php }; ?> 121 <script type="text/javascript"> 122 onload=document.getElementById('back').href="javascript:history.back();"; 123 </script> 124 </div> 125 </div><!-- right --> 43 126 44 127 <div style="clear:both;"></div><div id="pata"> … … 52 135 </body> 53 136 </html> 54 <?php55 };56 ?>
Note:
See TracChangeset
for help on using the changeset viewer.