PHP skript
PHP skript
potrebujem skript ktory zobrazi všetky fotky bez udania nazvu fotky..Keby mu stačilo že to je JPG na to aby ju zobrazilo..
-
audiotrack
VIP
- Príspevky: 25958
- Registrovaný: 09 sep 2005, 18:39
- Kontaktovať používateľa:
napríklad takto: treba sa pohrať so štýlmi tých fotiek aby to vypadalo k svetu
Kód: Vybrať všetko
<?php
$adresar = "./images/";
if ($handle = opendir($adresar))
{
while ($file = readdir($handle))
{
if (strpos($file,".jpg") || strpos($file,".JPG"))
{
if ($j % 3 == 0)
{
$directories .= "<tr>";
}
$directories .= "<td height='40' width='40' align='center' ><img src='".$adresar.$file."' height='60' width='100'></td>\n";
if (($j % 3) == 3)
{
$directories .= "</tr>";
}
$j++;
}
}
echo $directories;
closedir($handle);
}
?>