I have the following code that swaps a primary image when a thumbnail is clicked:
$('#thumbs img').click(function(){
var imgsrc = $(this).attr('src');
$('#mainphoto img').fadeOut(function(){
$(this).attr('src', imgsrc).fadeIn();
});
});
There is a working example here: http://clarkeconstructions.com.au/newsite/index.php?id=8
Some of the images are portrait shots and some are landscape (if you click the 2nd thumbnail in the example).
I want to be able to slide the image down to made the transition of landscape to portrait smoother but I am not sure how to go about it with my current code.
Would anyone be able to give me any hints as to what syntax I would use to accomplish this?
Thanks