gumper gumper - 2 years ago 84
CSS Question

set the div to position:relative from position:absolute; when using turn.js

this is a simple question, I've just started using the turn.js library and want to relatively position image elements with reference to a container div, to do this, it would look something like:

<div id="cont" style="position:relative;">//this div acts a page
<img src="my.jpg" style="position: absolute; top:40px; left:50px;">

the div, using the library, would serve as the page to be flipped, the problem is that whenever i set the container div to position relative, it gets turned into position absolute automatically by the turn.js library when the page loads, is there a way to ensure that the divs which get turned into pages all have position:relative; instead of position:absolute;? Thank You in advance.

Answer Source

Try this hope this may solve your problem

#cont {
  position:relative !important;
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download