In this blog it is explained how to create photo gallery using html, css and jquery.
- write simple html to add images.
Each image is within div has class thumbnail_inner. which is surrounded by div has class thumbnail. current class is show thumbnail of image which is displayed currently. class big_photo display large image display on screen.
2. include(using link) css file in head of html and write following code inside it.
opacity of thumbnail is 0.4 except current thumbnail.
3. add jquery library and jquery script inside head of html.
when user click on thumbnail it remove class current from any thumbnail and it add class current in thumbnail clicked by user.
here we take one variable path which store source attribute of image and copy that path to source attribute of large photo.