Jump to content

on :hover cover all elements within div?


liamloveslearning

Recommended Posts

Hi all,

 

I have a div containing a thumbnail and an image, eg...

<div class="box">
<img src="myimg.jpg" /><p>text</p>
</div>

 

I have the style...

.box {width:100px; height:100px; display:block; float:left;}
.box:hover { background-image:my background image.jpg; }

 

Only when I hover over my div the background image is being called only it shows BENEATH the image inside. I've tried changing z-indexes with no luck, Any ideas?

Link to comment
https://forums.phpfreaks.com/topic/213987-on-hover-cover-all-elements-within-div/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.