hi guys, i’m developing a property rental site, and i’d like to allow the owner to be able to click a link and bring up a photo gallery of thumbnails showing all uploaded images.
can you tell me or point me to a tutorial that will turn the whole image directory of only .jpg images into a thumbnail gallery.
i want php to auto-detect all the .jpg files in the ‘image’ directory and then create a thumbnail gallery of clickable/linked images with their short filename appended as pid=”filename.jpg” like this …
[CODE]
<div style=”width:700″>
<a href=”UpdatePhoto.php?pid=fireplace.jpg”>
<img src=”fireplace.jpg” height=”125″ width=”125″>
</a>
</div>
<a href=”UpdatePhoto.php?pid=bathroom.jpg”>
<img src=”bathroom.jpg” height=”125″ width=”125″>
</a>
etc.
i can style and pad the images and all that, i just need
php to auto-detect the jpegs and link them with their
short filename as the $pid variable.
UpdatePhoto.php already knows what to do with $pid,
but i don’t want to hard code the list of files, i want php
to simpl detect the images and link them for me.
thanks for your assistance.
p.s. i found some ready made scripts that list the
contents but i find it difficult to modify plus they
list every type of file, i only need it to recognize images,
so i don’t need all that extra code that recognizes every
other file type.