Search code examples
phpimagetwitter-bootstrapstylestwitter-bootstrap-2

Using Bootstrap 2.3.2, what is a good method of styling an image gallery


I am trying to create an image gallery on my real estate website that displays only the images associated with the property selected. I have the following code that allows me to bring up the images associated with the property. My issue now is trying to create an image gallery from this. Any ideas on how to do this? I am using Bootstrap 2.3.2 to build the site.

<?php
$path = "../uploads";
foreach (glob("$path/{$_SESSION['propertyid']}*") as $filename):
?>
    <img src="<?php echo $path ?>/<?php echo $filename ?>" alt="photo" width="250" height="250" border="0" /><br><br>
<?php endforeach ?>

Solution

  • I would comment with this question and then answer this but I must have 50 rep to comment.

    My question is why are you still using 2.3.2. Why not upgrade to 3.2? That is just pure curiosity. Regardless of the answer, I have had to do this before. I am not proficent with entering code correctly on stackoverflow yet so here is a pastebin link. BTW, I had to go digging through an old pastebin account for this.

    http://pastebin.com/kPA6Vq0g