I noticed a strange problem with my stacking order when applying the webkit filter. Why, when I hover over the image, does the stacking order change?
I would prefer not to use z-indexing to fix this, since it breaks up other elements of the site.
Here is my JSFiddle http://jsfiddle.net/r13ycy1p/
Sorry Homer, I just need an image.
EDIT: How can I undo effects to prevent hiding the absolute position of the div?
Here is my html
<ul> <li> <a href="#"> <div class="slide-content"> <div class="slide-title"> <h1>hello world</h1> </div> <div class="slide-desc"> <p>a description about something</p> </div> </div> <img src="http://img4.wikia.nocookie.net/__cb20130920142351/simpsons/images/e/e9/Pic_1187696292_8.jpg"/> </a> </li> </ul>
CSS
li { list-style:none; } .slide-content { position:absolute; color:red; top:50px; } li a:hover img{ -webkit-filter: grayscale(100%); }
css filter z-index webkit
KingLouie Sep 10 '14 at 11:37 2014-09-10 11:37
source share