View Full Version : How do I add the z index?
10-28-2011, 12:02 PM
How do I add z index so this always stays on top?
<div class="fb-like" data-href="www.website.co.uk" data-send="false" data-width="450" data-show-faces="false"></div>
in the css style part or file, you can try something like that:
please note that the value of z-index depends of the number of layers you have so it can be more than 1.
10-28-2011, 12:48 PM
Simple as that! Except it doesn't cure my problem.
The like button opens a balloon when clicked which is under the element beneath it on the page.
I set the z to 9999, but doesn't help. What else could I try? It's at dplsolar.co.uk
10-28-2011, 03:43 PM
First, z-index has nothing to do with the number of layers you have.
Secondly, z-index only works on relative and absolutely positioned elements. If your element is not positioned like that, the z-index won't matter.
Third, if the like button is in a separate parent container than the other element, there is some finagling you will need to do. This site is an interactive example of how z-index works with positioned elements:
Powered by vBulletin® Version 4.2.2 Copyright © 2017 vBulletin Solutions, Inc. All rights reserved.