CSS Library: Image CSS: Here
CSS Popup Image Viewer
Author: Dynamic Drive
Enable arbitrary links or image thumbnails to pop up an enlarged (different) image onMouseover by using this CSS code. With the help of CSS's ":hover" pseudo class, combined with relative and absolute positioning, the enlarged images are simply included on the page as normal HTML, "popping" up on demand. CSS is behaving more and more like scripting!
Demo:
One of my favorite foods is sushi
Doesn't this look good?, and it's good for you too! Coffee and sushi probably don't mix well, but I like some Zoka Coffee
Zoka Coffee to boot! Here are some thumbnails from my trip to La la land:
![]()

Simply beautiful.
![]()

So real, it's unreal. Or is it?
The CSS:
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 35 of 41 pages « First < 33 34 35 36 37 > Last »
<html><head>
<link rel="stylesheet" type="text/css" href="css/popup_image.css" >
<a class="thumbnail" href="#thumb">
jpg/tree_thumb.jpg
<span>jpg/tree.jpg
Simply beautiful.</span></a>
<a class="thumbnail" href="#thumb">
jpg/ocean_thumb.jpg<span>jpg/ocean.jpg
So real, it's unreal. Or is it?</span></a>
<a class="thumbnail" href="#thumb">Dynamic Drive<span>gif/dynamicdrive.gif
Dynamic Drive</span></a>
<a class="thumbnail" href="#thumb">Zoka Coffee<span>gif/zoka.gif
Zoka Coffee</span></a>
<html>This work directly if u copy .css file in 1 css folder, and up picture. If u know little web language is simple.
Thanks!
To get the popped up image to be a clickable link in and of itself, you can add onclick="location='somepage.html'" to its img tag like this ...
... <span>poppedthumb.jpg</span> ...I got the information from this page : http://www.carlaereyes.com/portfolio/index.php?tag=portfolio:menu=fine32art
My next problem was to get consist layout between IE and Firefox ... the offset of the popped up image was all over the show and I wanted it centered above my thumbnail. This is my own 'fix' and I'm just a beginner so I can't guarantee it's not bad somehow, but so far it works :D on my page anyway ... it may be something wrong with the CSS layout that's breaking how the image pops ...
My popped image layout fix for Firefox vs IE
Define the layout for the popped up thumnail in your
.thumbspop:hover span{
left:100px;
top:100px;
}or whatever you like. Then, after that </style> add this
<!--[if IE]>
<style>.thumbspop:hover span{ top:75px; left:75px; }</style>
<![endif]-->and adjust top and left so it's perfect in IE ;) Done!
add the onclick="Location... like this
... <span>thumb.jpg</span></a>
Ok in the IMG tag, add onclick="location:'somepage.html'" in between the the <img and the src="" parts ... like you would a normal onclick command ...
... let's see if it gets canned this time LOLstr
When one hovers over the bottom images for example the enlarged image opens at the top of the page and the viewer will not be able to see it.
nice effect!!
Can you tell me how to get two or more photos to change by themselves?
Help me!!
thanks
Mavi
Comment Pages 35 of 41 pages « First < 33 34 35 36 37 > Last »









