Thread: To hide a div
View Single Post
Old 08-10-2007, 02:07 PM   #5 (permalink)
MacPC
New Member
 
Join Date: May 2007
Posts: 12
Default

Yea, it works!
What I did was:
div.box {
position: relative;
background: url(images/box_8bkg.gif);
top: 100px;
left: 0px;
width: 252px;
height: 212px;
border: 0px solid green;
z-index: 10;
}

div.box:hover {
background: transparent;
width: 0px;
height: 0px;
}

This covers a embeded video with a background image, the video can only be seen when the mouse is over it. It works on Safari and FF (it flickers tho), as always, stupid IE 7 needs a bit of twaeks and doesn't work on the crappy IE 6 at all since IE6 doesn't support :hover on any other elements but the anchor.
MacPC is offline   Reply With Quote