minipet php
<?php
# Copyright by: Nero
# Modified by: Liquid Skies & lordrepha
# www.gw-buendnis.de Die Guild Wars Fanseite
defined ('main') or die ( 'no direct access' );
$title = $allgAr['title'].' :: Minipets';
$hmenu = 'Minipets';
$design = new design ( $title , $hmenu );
$design->header();
$idchoos = escape($_POST['idchoos'], 'string');
$idchoos2 = escape($_POST['idchoos2'], 'string');
$idchoos3 = escape($_POST['idchoos3'], 'string');
$tpl = new tpl ( 'minipets' );
$tpl->out(0);
//$url = escape($_POST['url'],'string'); // Übergabe der Variable aus den SelectFenstern
//$abfrage = db_fetch_assoc(db_query("SELECT * FROM prefix_minipets WHERE Name = 'url' "));
//------------------------- Alle Klassen3, Alle Kapitel2, Waffe1 irgendwas----------------
if(($idchoos3 == "Alle Klassen")AND($idchoos2 == "Alle Laender"))
{
$abfrage = "SELECT * FROM prefix_minipets WHERE Gattung = '$idchoos' ORDER BY 'Name'";
$ergebnis = db_query($abfrage);
while($row = db_fetch_assoc($ergebnis))
{
$row["betext"] = str_replace("\n", "<br>", $row["betext"]);
$row['url'] = '<img src ="/legionofsun/include/images/Minipets/Minipets/'.$row['Name'].'.jpg"';
$tpl->set_ar($row);
//$tpl->set_ar($url);
$tpl->out(1);
}
}
//-------------------Alle Klassen3, Alle Waffen1, Kapitel2 irgendwas------------------
if
(($idchoos3 == "Alle Klassen")AND($idchoos == "Alle Waffen"))
{
$abfrage = "SELECT * FROM prefix_minipets WHERE Kapitel = '$idchoos2' ORDER BY 'Name'";
$ergebnis = db_query($abfrage);
while($row = db_fetch_assoc($ergebnis))
{
$row["betext"] = str_replace("\n", "<br>", $row["betext"]);
$row['url'] = '<img src ="/legionofsun/include/images/Minipets/Minipets/'.$row['Name'].'.jpg"';
echo $tpl->set_ar_out($row,1);
}
}
//------------------Alle Waffen1,Alle Kapitel2, Klassen3 irgendwas------------------
if
(($idchoos2 == "Alle Laender")AND($idchoos == "Alle Waffen"))
{
$abfrage = "SELECT * FROM prefix_minipets WHERE Klasse = '$idchoos3' ORDER BY 'Name'";
$ergebnis = db_query($abfrage);
while($row = db_fetch_assoc($ergebnis))
{
$row["betext"] = str_replace("\n", "<br>", $row["betext"]);
$row['url'] = '<img src ="/legionofsun/include/images/Minipets/Minipets/'.$row['Name'].'.jpg"';
echo $tpl->set_ar_out($row,1);
}
}
//-------------------- Alle Klassen-----------------
if($idchoos3 == "Alle Klassen")
{
$abfrage = "SELECT * FROM prefix_minipets WHERE Gattung = '$idchoos' AND Kapitel = '$idchoos2' ORDER BY 'Name'";
$ergebnis = db_query($abfrage);
while($row = db_fetch_assoc($ergebnis))
{
$row["betext"] = str_replace("\n", "<br>", $row["betext"]);
$row['url'] = '<img src ="/legionofsun/include/images/Minipets/Minipets/'.$row['Name'].'.jpg"';
echo $tpl->set_ar_out($row,1);
}
}
elseif
//---------------------------Alle Länder-----------------------
($idchoos2 == "Alle Laender")
{
$abfrage = "SELECT * FROM prefix_minipets WHERE Gattung = '$idchoos' AND Klasse = '$idchoos3' ORDER BY 'Name'";
$ergebnis = db_query($abfrage);
while($row = db_fetch_assoc($ergebnis))
{
$row["betext"] = str_replace("\n", "<br>", $row["betext"]);
$row['url'] = '<img src ="/legionofsun/include/images/Minipets/Minipets/'.$row['Name'].'.jpg"';
echo $tpl->set_ar_out($row,1);
}
}
elseif//------------------------- Alle Waffen-------------------
($idchoos == "Alle Waffen")
{
$abfrage = "SELECT * FROM prefix_minipets WHERE Kapitel =
'$idchoos2' AND Klasse = '$idchoos3' ORDER BY 'Name'";
$ergebnis = db_query($abfrage);
while($row = db_fetch_assoc($ergebnis))
{
$row["betext"] = str_replace("\n", "<br>", $row["betext"]);
$row['url'] = '<img src ="/legionofsun/include/images/Minipets/Minipets/'.$row['Name'].'.jpg"';
echo $tpl->set_ar_out($row,1);
}
}
else
{
$abfrage = "SELECT * FROM prefix_minipets WHERE Kapitel =
'$idchoos2' AND Gattung = '$idchoos' AND Klasse = '$idchoos3'";
$ergebnis = db_query($abfrage);
while($row = db_fetch_assoc($ergebnis))
{
$row["betext"] = str_replace("\n", "<br>", $row["betext"]);
$row['url'] = '<img src ="/legionofsun/include/images/Minipets/Minipets/'.$row['Name'].'.jpg"';
echo $tpl->set_ar_out($row,1);
}
}
//----------------------------- Gesamte Datenbank------------------
if($idchoos2 == "Alle Laender")
{
if ($idchoos == "Alle Waffen")
{
if ($idchoos3 == "Alle Klassen")
$abfrage = "SELECT * FROM prefix_minipets";
$ergebnis = db_query($abfrage);
while($row = db_fetch_assoc($ergebnis))
{
$row["betext"] = str_replace("\n", "<br>", $row["betext"]);
$row['url'] = '<img src ="/legionofsun/include/images/Minipets/Minipets/'.$row['Name'].'.jpg"';
echo $tpl->set_ar_out($row,1);
}}}
$tpl->out(2);
echo mysql_error();
$design->footer();
?>
minipet htm
<style type="text/css">
<!--
.Stil2 {
color: #009900;
font-weight: bold;
}
.Stil5 {color: #FF9900}
.Stil7 {color: #000000}
.Stil8 {color: #000000}
.Stil9 {color: #000000}
.Stil12 {font-size: 12px}
-->
</style>
<table width="100%" border="0">
<tr>
<td width="100%" height="100%"><?php
include("minipets.php");
?>
<form action="index.php?minipets" method="post" enctype="multipart/form-data" target="_self" class="Stil9">
<div align="center">
<table width="100%" border="0">
<tr><td width="120"><select name="idchoos" id="select4">
<option value="Alle Waffen" selected>Alle Farben</option>
<option value="Gruen">Gruen</option>
<option value="Gold">Gold</option>
<option value="Weiß">Weiß</option>
<option value="Lila">Lila</option>
</select></td>
<td width="114"><select name="idchoos2" id="select5">
<option value="Alle Laender" selected>Wann? Wo? Wie?</option>
<option value="Geburtstagsgeschenke">Geburtstagsgeschenke</option>
<option value="Collectors Edition">Collectors Edition</option>
<option value="Spezielle Veranstaltungen">Spezielle Veranstaltungen</option>
<option value="Im Spiel">Im Spiel</option>
</select></td>
<td width="27"> </td>
<td width="8"> </td>
<td width="3"></td>
<td width="68"> </td>
</tr>
<tr>
<td><select name="idchoos3" id="idchoos3">
<option value="Alle Klassen" selected>Minipets</option>
<option {sel_klasse_Krieger} value="Knochendrache">Knochendrache</option>
<option {sel_klasse_Mesmer} value="Prinz Rurik">Prinz Rurik</option>
<option {sel_klasse_Waldlaeufer} value="Shiro Tagachi">Shiro Tagachi</option>
<option {sel_klasse_Ritualist} value="Brennender Titan">Brennender
Titan</option>
<option {sel_klasse_Assasine} value="Charr-Schamane">Charr-Schamane</option>
<option {sel_klasse_Derwisch} value="Kirin">Kirin</option>
<option {sel_klasse_Paragon} value="Belagerung-Schildkröte">
Belagerung-Schildkröte</option>
<option {sel_klasse_Paragon} value="Tempelwächter">Tempelwächter</option>
<option {sel_klasse_Paragon} value="Peitschenschwanz-Verschlinger">
Peitschenschwanz-Verschlinger</option>
<option {sel_klasse_Paragon} value="Todesreiter">Todesreiter</option>
<option {sel_klasse_Paragon} value="Dschungel-Troll">Dschungel-Troll</option>
<option {sel_klasse_Waldlaeufer} value="Jade-Rüstung">Jade-Rüstung</option>
<option {sel_klasse_Ritualist} value="Hydra">Hydra</option>
<option {sel_klasse_Assasine} value="Pilzsuhler">Pilzsuhler</option>
<option {sel_klasse_Derwisch} value="Harpyien-Waldläufer">
Harpyien-Waldläufer</option>
<option {sel_klasse_Krieger} value="Steinaxt-Heket">Steinaxt-Heket</option>
<option {sel_klasse_Mesmer} value="Klingen-Aatxe">Klingen-Aatxe</option>
<option {sel_klasse_Moench} value="Windreiter">Windreiter</option>
<option {sel_klasse_Waldlaeufer} value="Dornenwolf">Dornenwolf</option>
<option {sel_klasse_Ritualist} value="Feuer-Kobold">Feuer-Kobold</option>
<option {sel_klasse_Assasine} value="Alraunen-Kobold">
Alraunen-Kobold</option>
<option {sel_klasse_Derwisch} value="Moloch">Moloch</option>
<option {sel_klasse_Paragon} value="Elf">Elf</option>
<option {sel_klasse_Paragon} value="Koss">Koss</option>
<option {sel_klasse_Paragon} value="Palawa Joko">Palawa Joko</option>
<option {sel_klasse_Paragon} value="Wasser-Dschinn">Wasser-Dschinn</option>
<option {sel_klasse_Paragon} value="Lich">Lich</option>
<option {sel_klasse_Waldlaeufer} value="Kuunavang">Kuunavang</option>
<option {sel_klasse_Ritualist} value="Varesh">Varesh</option>
<option {sel_klasse_Assasine} value="Kanaxai">Kanaxai</option>
<option {sel_klasse_Derwisch} value="Vizu">Vizu</option>
<option {sel_klasse_Krieger} value="Panda">Panda</option>
<option {sel_klasse_Mesmer} value="Inselwächter">Inselwächter</option>
<option {sel_klasse_Moench} value="Zhed Schattenhuf">Zhed
Schattenhuf</option>
<option {sel_klasse_Waldlaeufer} value="Shiro'ken-Assassine">
Shiro'ken-Assassine</option>
<option {sel_klasse_Ritualist} value="Geölter Blitz">Geölter Blitz</option>
<option {sel_klasse_Assasine} value="Grauer Riese">Grauer Riese</option>
<option {sel_klasse_Derwisch} value="Asura">Asura</option>
<option {sel_klasse_Paragon} value="Langhaar-Yeti">Langhaar-Yeti</option>
<option {sel_klasse_Paragon} value="Naga-Regenrufer">Naga-Regenrufer</option>
<option {sel_klasse_Paragon} value="Oni">Oni</option>
<option {sel_klasse_Paragon} value="Geisterheld">Geisterheld</option>
<option {sel_klasse_Paragon} value="Mallyx">Mallyx</option>
<option {sel_klasse_Waldlaeufer} value="Miniaturschwein">
Miniaturschwein</option>
</select></td>
<td><input name="submit" type="submit" id="submit2" value="Suche Starten"></td>
<td> </td>
<td> </td>
<td> </td>
<td> </td>
</tr>
<tr>
<td> </td>
<td><span class="Stil12">Sponsored by <a href="http://www.gw-buendnis.de">GW-Buendnis.de </a></span></td>
<td> </td>
<td> </td>
<td> </td>
<td> </td>
</tr>
</table>
</div>
</form>
<div align="center"> </div>
<p align="center">
</p>
<div align="center">
<table width="91%" class="border" border="1" cellpadding="3" cellspacing="1" bordercolor="#000000">
<tr class="Chead">
<td>Name</td>
<td>Farbe</td>
<td>Beschreibung</td>
</tr>
<p>{EXPLODE}
<tr>
<td><p class="Stil2">{Name}</p>
<p class="Stil9">{url}</p>
<p class="Stil5">Wann: <span class="Stil8">{Kapitel}</span></p>
<p class="Stil5"><span class="Stil7"> <span class="Stil8">{Fundort}</span></span></p></td>
<td><p>{Gattung} </p>
<p> </p></td>
<td><p>{betext} </p>
<p> </p></td>
</tr>
{EXPLODE}
</table>
</div>
</td>
</tr>
</table>
bitte den link zu uns nicht entfernen