Thank you Matti
How could I then count the number of .bsp files and display that?
Also I am using the following code(very messy, I know) to get all images inside a directory and display them on after another with their names. How could I make them display in a 3 column table, each cell holding an image, and an image name?
php code:
Map images:<br><Br>
<?php
$folder = opendir("C:\Inetpub\wwwroot\lgsl\lgsl_files\maps\source\zombie_master");
$pic_types = array("jpg", "jpeg", "gif", "png");
$index = array();
while ($file = readdir ($folder)) {
if(in_array(substr(strtolower($file), strrpos($file,".") + 1),$pic_types))
{
array_push($index,$file);
}
}
closedir($folder);
?>
<?php
$path = "C:\Inetpub\wwwroot\lgsl\lgsl_files\maps\source\zombie_master";
$dir_handle = @opendir($path) or die("Unable to open folder");
while (false !== ($file = readdir($dir_handle))) {
if(ereg("(.*)\.(jpg|bmp|jpeg|png|gif)", $file)){
echo "$file<br><img src='http://sammyservers.com/lgsl/lgsl_files/maps/source/zombie_master//$file' alt='$file'><br />";
}
}
closedir($dir_handle);
?>