"vse"): $uplny_dotaz="SELECT * FROM `Mineraly` WHERE Trida LIKE '%"."$trida"."%'"; endif; if ($uco=="" && $nazev<>"" && $trida=="vse"): $uplny_dotaz="SELECT * FROM `Mineraly` WHERE Englisch LIKE '%"."$nazev"."%'"; endif; if ($uco=="" && $lokalita<>"" && $trida=="vse"): $uplny_dotaz="SELECT * FROM `Mineraly` WHERE Lokalita LIKE '%"."$lokalita"."%'"; endif; if ($uco=="" && $stat<>"" && $trida=="vse"): $uplny_dotaz="SELECT * FROM `Mineraly` WHERE Locality LIKE '%"."$stat"."%'"; endif; if ($uco=="" && $nazev<>"" && $trida<>"vse"): $uplny_dotaz="SELECT * FROM `Mineraly` WHERE (Englisch LIKE '%"."$nazev"."%') AND (Trida LIKE '%"."$trida"."%')"; endif; if ($uco=="" && $lokalita<>"" && $trida<>"vse"): $uplny_dotaz="SELECT * FROM `Mineraly` WHERE (Lokalita LIKE '%"."$lokalita"."%') AND (Trida LIKE '%"."$trida"."%')"; endif; if ($uco=="" && $stat<>"" && $trida<>"vse"): $uplny_dotaz="SELECT * FROM `Mineraly` WHERE (Locality LIKE '%"."$stat"."%') AND (Trida LIKE '%"."$trida"."%')"; endif; if ($uco=="" && $nazev<>"" && $lokalita<>"" && $trida=="vse"): $uplny_dotaz="SELECT * FROM `Mineraly` WHERE (Englisch LIKE '%"."$nazev"."%') AND (Lokalita LIKE '%"."$lokalita"."%')"; endif; if ($uco=="" && $nazev<>"" && $stat<>"" && $trida=="vse"): $uplny_dotaz="SELECT * FROM `Mineraly` WHERE (Englisch LIKE '%"."$nazev"."%') AND (Locality LIKE '%"."$stat"."%')"; endif; if ($uco=="" && $stat<>"" && $lokalita<>"" && $trida=="vse"): $uplny_dotaz="SELECT * FROM `Mineraly` WHERE (Locality LIKE '%"."$stat"."%') AND (Lokalita LIKE '%"."$lokalita"."%')"; endif; if ($uco=="" && $nazev<>"" && $lokalita<>"" && $trida<>"vse"): $uplny_dotaz="SELECT * FROM `Mineraly` WHERE (Englisch LIKE '%"."$nazev"."%') AND (Lokalita LIKE '%"."$lokalita"."%') AND (Trida LIKE '%"."$trida"."%')"; endif; if ($uco=="" && $nazev<>"" && $stat<>"" && $trida<>"vse"): $uplny_dotaz="SELECT * FROM `Mineraly` WHERE (Englisch LIKE '%"."$nazev"."%') AND (Locality LIKE '%"."$stat"."%') AND (Trida LIKE '%"."$trida"."%')"; endif; if ($uco=="" && $stat<>"" && $lokalita<>"" && $trida<>"vse"): $uplny_dotaz="SELECT * FROM `Mineraly` WHERE (Locality LIKE '%"."$stat"."%') AND (Lokalita LIKE '%"."$lokalita"."%') AND (Trida LIKE '%"."$trida"."%')"; endif; if ($uco=="" && $nazev<>"" && $lokalita<>"" && $stat<>"" && trida=="vse" ): $uplny_dotaz="SELECT * FROM `Mineraly` WHERE (Englisch LIKE '%"."$nazev"."%') AND (Lokalita LIKE '%"."$lokalita"."%') AND (Locality LIKE '%"."$stat"."%')"; endif; if ($uco=="" && $nazev<>"" && $lokalita<>"" && $stat<>"" && trida<>"vse" ): $uplny_dotaz="SELECT * FROM `Mineraly` WHERE (Englisch LIKE '%"."$nazev"."%') AND (Lokalita LIKE '%"."$lokalita"."%') AND (Locality LIKE '%"."$stat"."%') AND (Trida LIKE '%"."$trida"."%')"; endif; if ($uco<>""): $uplny_dotaz="SELECT * FROM `Mineraly` WHERE Uco LIKE '%"."$uco"."%'"; endif; if ($posledni>0): $uplny_dotaz="SELECT * FROM `Mineraly` WHERE datum > SUBDATE( NOW( ),INTERVAL "."$posledni"." HOUR)"; endif; $vysledek=@MySQL_Query($uplny_dotaz); $pocet=@MySQL_Num_Rows($vysledek); if ($pocet==0) echo "

No record found!

"; $pocet=$pocet/$kolik; $pocet_listu=Ceil($pocet); $list=($odkud/$kolik)+1; $stranka=@MySQL_Query($uplny_dotaz." LIMIT $odkud, $kolik"); while ($zaznam=@MySQL_Fetch_Array($stranka)): echo '"; $brake=1; else: $brake=0; endif; endwhile; $nazev=urlencode($nazev); $lokalita=urlencode($lokalita); $dotaz="nazev=$nazev&lokalita=$lokalita&stat=$stat&trida=$trida&uco=$uco&posledni=$posledni"; $u_dotaz=StrTr($dotaz, " ", "%"); echo "
'; echo '\n"; echo "
"; echo $zaznam["Englisch"]; echo "
"; echo $zaznam["Lokalita"]; echo ', '; echo $zaznam["Locality"]; echo "
"; echo 'Size: '; echo $zaznam["Sirka"]; echo "x"; echo $zaznam["Vyska"]; echo "mm"; if ($brake==0): echo "
"; if ($list>1) echo ""."First "." "; $parametr=$odkud-10; if ($list>1) echo ""."Prior "." "; $parametr=$odkud-50; $odkaz=$list-5; for ($i=0;$i<11; $i++): if ($list<6 && $kontrola==0): $odkaz=1; $i=6; $parametr=0; $kontrola=1; endif; if ($odkaz<=$pocet_listu): if ($odkaz<>$list): echo "$odkaz "; else: echo "$list "; endif; endif; $odkaz++; $parametr=$parametr+$kolik; endfor; $parametr=$odkud+10; if ($list<$pocet_listu) echo ""." Next"." "; $parametr=($pocet_listu*10)-10; if ($list<$pocet_listu) echo ""." Last"." "; ?>