The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums Other Where to start with a simple image gallery

  • This topic is empty.
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
  • #37516

    So I’m getting to a point on my website where I would like to add an image gallery.

    My knowledge at the moment only stretches as far as adding each individual image to an

  • and styling it in CSS. I know this is hugely inefficient.

    I can see there are numerous ways to do it – php, javascript, jQuery but without knowledge of any of these I’m getting bogged down with where to start. There are also lots of pre-created sliders, galleries etc but I want to retain the ability to style it.

    Can anyone point me in the right direction?



Thanks for that, although I’m specifically struggling to get my head round how you go from this….

To ‘cleaner’ markup that loops through, so you can dump additional images into a folder and it just picks them up.



Thanks kg, looks reasonable. Have you used this before?

I’m having some issues with the images actually displaying and can’t for the life of me figure out what’s wrong.

This is what I have in my test page….

Sample page

– Downloaded Lightbox plugin
– Downloaded Jquery
– Downloaded the files in the example
– Made sure the file names were all correct and in the right folder structure.

Directory list

…and just get a completely blank page

If I purposely put the wrong folder path in imgallery.php, I do see the correct formatting….

public function __construct(
$thumbsize=96, //Change this to match your thumbnail size
$maxsize=640, //Change this to match your maximum image size
$folderpath="./pictures", //Change this to match your folder path

I try adjusting $folderpath=”./imgallery/pictures” and I get a blank page.

Much hair has been shed so far…


Any luck with this?
I’m stuck on the blank page as well.

Viewing 4 posts - 1 through 4 (of 4 total)
  • The forum ‘Other’ is closed to new topics and replies.