Hi,
the best (but longest way) to do this is to create two versions of the images, one the thumbnail (low quailty and small pic) and the other version a normal sized good quailty image, its a pain in the butt really, if you want the pic to open up in a new window your best bet is to use javascript
OR a simple way is that I think Dreamweaver or Fireworks has got a photoalbum macro \ feature that does it all for you