Files
homepage/inhalte/rfoto.php
2023-12-28 12:13:55 +01:00

44 lines
939 B
PHP

<?php
if (isset($_GET['section'])) {
$path = "img/".$_GET['section']."/";
$link = "index.php?section=".$_GET['section']."&";
} else {
$path = "img/will/";
$link = "index.php?section=will&";
}
if (isset($_GET['t'])) {
$path .= $_GET['t']."/";
$link .= "t=".$_GET['t']."&";
}
if (isset($_GET['f'])) {
$pic = $path.$_GET['f'].".jpg";
echo " <img class=\"gross\" src=$pic />\n";
echo "</div>\n";
echo "<br class=\"clear\" />\n";
echo "<div id=\"thumb\">\n";
}
else {
for ($i=0; $i<10; $i++) {
$pic = $path.$i.".jpg";
if (file_exists($pic)) {
echo " <img class=\"gross\" src=$pic />\n";
echo "</div>\n";
echo "<br class=\"clear\" />\n";
echo "<div id=\"thumb\">\n";
break;
}
}
}
for ($i=9; $i>=0; $i--) {
$thumb = $path.$i.".jpg";
if (file_exists($thumb)) {
$ref = $link."f=$i";
echo " <a href=$ref><img src=$thumb /></a>\n";
}
}
echo "</div>\n";
?>