What i have is a row of flags on the top of my site, I have php grab the image from a folder with all of the images in them and echo them out. What i'v been trying to do is echo out the filename. (usa.jpg) etc. I havent been able to get a working code yet.. i must be making a very simple mistake..
This is my current code to retrieve and echo the photos out:
<?php
$files = glob("flagicons/*.*");
for ($i=1; $i<count($files); $i++)
{
$num = $files[$i];
echo '<img class="flag-class" src="'.$num.'">';
}
?>
This is my current code to retrieve and echo the photos out:
<?php
$files = glob("flagicons/*.*");
for ($i=1; $i<count($files); $i++)
{
$num = $files[$i];
echo '<img class="flag-class" src="'.$num.'">';
}
?>