Solved

Show content on hover

Posted on 2013-12-03
2
274 Views
Last Modified: 2013-12-03
If you go to the following jsfiddle link

http://bit.ly/1bdBqRt

What i am trying to accomplish is when you hover over the box the .content div area will show up.   But it isn't working
0
Comment
Question by:stargateatlantis
2 Comments
 
LVL 18

Accepted Solution

by:
Steven Harris earned 250 total points
ID: 39693287
Try using:

<div class='issue'><img src="http://images.kmag.co.uk/assets/images/latestfeatures/2013/11/Modu120.jpg" />
    <div class='issueTools'>
        <div class='content' style='color:red'>Content</span>        
    </div>
</div>

.issue {
    position: relative;
    display: inline-block;
}
.issue .issueTools {
    position: absolute;
    bottom: 0;
    opacity: .75;
}
.issue .issueTools .content {
    display: none;
}
.issue:hover .issueTools .content {
    display: block;
}

Open in new window

0
 
LVL 53

Assisted Solution

by:COBOLdinosaur
COBOLdinosaur earned 250 total points
ID: 39693770
Without the transitions:

<div class='issue'><img src="http://images.kmag.co.uk/assets/images/latestfeatures/2013/11/Modu120.jpg" />
        <div class='content'>Content</div>        
</div>

.issue {
     position:relative;
     width:200px;
    height:259px;
    background:url('http://images.kmag.co.uk/assets/images/latestfeatures/2013/11/Modu120.jpg') 100%;
           }
.content {
     display:none;color:red;
     position: absolute;
    bottom: 0;
    opacity: .75;
    display:none;
               }
.issue:hover {
       opacity: .75;
         }
.issue:hover .content { 
       display:block;
       z-index:5;
               }

Open in new window

Once you have the basic effect you can add the transitions.

Cd&
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Positioning of an element a percentage from the top. 14 32
HTML CSS 7 38
Add animation to your css 12 32
FIELDSETs and LEGENDs in email markup 1 13
Creating a CSS block that only applies to printing By default, all of your CSS applies to every possible view of your page - whether on screen, printed, landscape, touch-screen, or whatever.  You can, however, add CSS that only applies under certai…
Building a website can seem like a daunting task to the uninitiated but it really only requires knowledge of two basic languages: HTML and CSS.
In this tutorial viewers will learn how to style different bullet points for unordered lists in CSS. Begin with a normal unordered list; the default bullet point is a solid circle: In the CSS, create a defined class of unordered list by typing "ul.S…
Learn how to create flexible layouts using relative units in CSS.  New relative units added in CSS3 include vw(viewports width), vh(viewports height), vmin(minimum of viewports height and width), and vmax (maximum of viewports height and width).

895 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

15 Experts available now in Live!

Get 1:1 Help Now