Advanced Search Usage Terms Submit Contact
Dynamic Drive CSS Library
 
CSS Library
Submit an original CSS code
CSS Layouts
Online Tools:

Advertise Here

CSS Library: Image CSS: Here

CSS Image Gallery

Author: Dynamic Drive

This is a purely CSS based image gallery that displays larger versions of thumbnail images dynamically when the mouse hovers over them. A rich HTML caption can be added to the enlarged image, and every aspect of the Image Gallery exists as plain HTML on the page. The idea is to use CSS's ":hover" pseudo class to cause an element to react onMouseover. When that happens, an absolutely positioned container holding the enlarged image, anchored on the page by another container with position set to relative, is shown. Furthermore, it's possible to modify the behavior so the enlarged images are only shown onClick, though IE6 currently doesn't support this behavior well. The gallery works in IE6+, Firefox, Opera 8+.

Demo:

Note: Here the enlarged images are set to "overlay" any content that it may come in contact with. You can easily disable overlaying just by giving the gallery container (.gallerycontainer) a height set to that of the largest image's.

The CSS:

The HTML:

Code Info

Rate this code:

Date Posted: 05/07/2006

Revision History: None

Usage Terms: Click here

Your Comments (257)

Got a question or need help customizing this CSS code? Post it in the CSS Forums. If you have a comment or suggestion instead, post it in the comments section below.

Comment Pages 26 of 26 pages « First  <  24 25 26

How can i get the large photos to be placed a little lower on the page? At the moment they are going over the top of my menu bar? I am only using the text sample, not the photo one

PLEASE HELP
Posted by brad on 04/23, 07:57 PM
how can i use that code for drupal ?
Posted by rujak on 05/02, 07:10 PM
really simple fast aproach! thanks!
Posted by tobto on 05/05, 11:18 AM
any idea how to keep the images on after mouse out.
i dont like the fact that they dissapear. not sure if this can be done with css alone.
Posted by james on 05/05, 08:52 PM
So good, i will use
Posted by MyDesign.com.ar on 05/06, 10:12 AM
Are the best this thinks... I put on my sites www.legendofmir.ro
Posted by DOOMNEZEU on 05/09, 10:47 AM
This CSS thumbnail gallery is neat. When going to thumbnail, I just want bigger image/text stay. - mouseout or something.

Please help. Thanks.
Posted by Michael on 05/13, 01:13 PM

Comment Pages 26 of 26 pages « First  <  24 25 26

Name: (Required)

Email: (Required)

(NOT shown on page)

URL:

(Shown on page if entered)

Comments: (Required)

Supported BB codes: [b], [i], [u], [em], [strike], [strong], [pre], [code], and [blockquote].

Remember my personal information
Notify me of follow-up comments?

Submit the word you see below ("previewing" post does not require it):


Copyright 2006 Dynamic Drive Read our Usage Terms before using any of the CSS codes.
Dynamic Drive DHTML and CSS Code Library