Solved

displaying blow-up image using only CSS

Posted on 2007-11-29
5
1,692 Views
Last Modified: 2013-11-19
Hello,

In the link I listed there is a black swatch rectangle. I am trying to use only CSS and XHTML to display a larger image when the mouse rolls over the swatch image. The swatch image you can see is 225px, and I want to also let the user see a larger image either with a popup or with a rollover, but I can't use javascript. Or if you have another idea that would be cool too.

Thanks!
0
Comment
Question by:weikelbob
  • 2
  • 2
5 Comments
 
LVL 7

Accepted Solution

by:
Wod earned 500 total points
Comment Utility
0
 
LVL 7

Author Comment

by:weikelbob
Comment Utility
It's not working:

https://www.weddingmountain.com/pc-5577-546-satin-ribbon-edge-seans-test-2.aspx


<style type="text/css">
 

/*Credits: Dynamic Drive CSS Library */

/*URL: http://www.dynamicdrive.com/style/ */
 

.thumbnail{

position: relative;

z-index: 0;

}
 

.thumbnail:hover{

background-color: transparent;

z-index: 50;

}
 

.thumbnail span{ /*CSS for enlarged image*/

position: absolute;

background-color: white;

padding: 5px;

left: -1000px;

border: 1px solid black;

visibility: hidden;

color: black;

text-decoration: none;

}
 

.thumbnail span img{ /*CSS for enlarged image*/

border-width: 0;

padding: 2px;

}
 

.thumbnail:hover span{ /*CSS for enlarged image on hover*/

visibility: visible;

top: 0;

left: 60px; /*position where enlarged image should offset horizontally */
 

}
 

</style>

<a class="thumbnail" href="http://www.weddingmountain.com/skins/Skin_1/images/V70F-s_s225.jpg"><img src="http://www.weddingmountain.com/skins/Skin_1/images/V70F-s_s225.jpg" width="100px" height="66px" border="0" /><span><img src="http://www.weddingmountain.com/skins/Skin_1/images/V70F-s.jpg" /><br />Simply beautiful.</span></a>

Open in new window

0
 
LVL 7

Expert Comment

by:Wod
Comment Utility
Did you change the HTML to use the CSS?
0
 
LVL 7

Author Comment

by:weikelbob
Comment Utility
I'm using a shopping cart that supports CSS (aspdotnetstorefront). I don't think it supports your code. We aren't going to use a popup. Thank you for helping me out.

Good link though!

Thanks again,

Bob
0
 
LVL 4

Expert Comment

by:mandhjo
Comment Utility
I'm sure this is long since closed and gone, but I was able to get the code at the link working in AspDotNetStorefront.  Brilliant!  Thanks, Wod!
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Using SQL Scripts we can save all the SQL queries as files that we use very frequently on our database later point of time. This is one of the feature present under SQL Workshop in Oracle Application Express.
This article describes how to create custom column layout styles for Bootstrap. The article uses 5 columns to illustrate the concept, but the principle can be extended to any number of columns.
The viewer will receive an overview of the basics of CSS showing inline styles. In the head tags set up your style tags: (CODE) Reference the nav tag and set your properties.: (CODE) Set the reference for the UL element and styles for it to ensu…
The viewer will the learn the benefit of plain text editors and code an HTML5 based template for use in further tutorials.

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now