Hi all,
I am have this code exactly the way I want it but i wondered if you knew maybe how to add the same img in the html[<a href="<? '$filePath$img' ?>"] as in the php [echo "<img src='$filePath$img'/>";]
ThanksCode:<?
$string =array();
$filePath='images/photos/';
$dir = opendir($filePath);
while ($file = readdir($dir)) {
if (eregi("\.png",$file) || eregi("\.jpg",$file) || eregi("\.gif",$file) ) {
$string[] = $file;
}
}
while (sizeof($string) != 0){
$img = array_pop($string);
?>
<a href="<? '$filePath$img' ?>" class="galpop" data-galpop-group="gallery">
<?
echo "<img src='$filePath$img'/>";
}
?>
</a>

