Michael Angstadt's Homepage
< Back to Projects

ThumbThru

Overview

ThumbThru provides a simple way of displaying photos on a website. It's written completely in Javascript (with a stylesheet for formatting) and can be used immediately, right "out of the box".

I guess my "inspiration" came from the photo galleries found on the BBC News website. I needed something just like that--something simple and self-contained--so I decided to make my own clone!

It has been tested in Firefox and Safari, but should work on all other major browsers. Contact me or leave a comment if you discover otherwise.

Download

ThumbThru v0.1 + demo (released May 3 2008)

It is licenced under the LGPLv3

Installation

  1. Download it
  2. Add the Javascript file and CSS style sheet to your page:
    	<script src="thumb-thru.js" type="text/javascript"></script>
    	<link href="thumb-thru.css" type="text/css" rel="stylesheet" />
    
  3. Initialize and add photos to the gallery:
    <script language="javascript" type="text/javascript">
      var gallery = new ThumbThru('gallery');
      gallery.add('path/to/photo.jpg', 'Description of the photo.');
      gallery.add('path/to/photo2.jpg', 'My second photo.');
      //...
    </script>
    
  4. Display the gallery anywhere on your page:
    <script language="javascript" type="text/javascript">
      gallery.display();
    </script>
    

Demo