hab da ein Slideshowscript das alle Datein anstatt nur Bilder anzeigt....was muss ich verändern?
	
							
						
					PHP-Code:
	
	
<?
$img_directory = opendir(".");
while($img = readdir($img_directory))
{
$images[] = $img;
}
closedir($img_directory);
$size = count($images);
 if ($sp > 0)
 {
   $image = $images[$sp];
   if ($image == "")
   {
   print("You have reached the end of the images in this directory.");
   print("</BODY></HTML>");
   exit;
   }
   elseif ($image == "..") {
    $sp++;
    $image = $images[$sp];
   }
   elseif ($image == "slideshow.php3") {
    $sp++;
    $image = $images[$sp];
     if ($image == "")
    {
     print("You have reached the end of the images in this directory.");
     print("</BODY></HTML>");
     exit;
    }
   }
 } else {
   $break = explode(".", $image);
     if(($break[1] == "gif") OR ($break[1] == "jpg") OR ($break[1] == "png"))
     {
       $image = $images[0];
       if ($image == ".") { $image = $images[1]; $sp=1; }
       if ($image == "..") { $image = $images[2]; $sp=2;}
     }
 }
print("<img src=\"$image\">");
print("<br><p><input type=\"text\" name=\"imageurl\" size=\"45\" value=\"http://www.fsabi2003.it-pc.de/$image\" size='+fieldsize+' style=\"background:#FFFFFF; border:1 #333333 solid; font-size:9px; color:#111111\"></p><br>");
$sp++;
?>
<form method="post" action="slideshow.php3">
<input type="hidden" name="sp" value="<?print($sp);?>">
<input type="submit" value="Next Picture" size='+fieldsize+' style="background:#FFFFFF; border:1 #333333 solid; font-size:9px; color:#111111">
</form>
          
Kommentar