0

I have an iframe which has a PDF document. I also have a div that I want to display over that PDF file.

HTML CODE

<iframe width="200" height="200" src="abc.pdf" style="border:1px solid #000"></iframe>
<div style="width:200px; height:50px; border:1px solid #000; background:red; position:absolute; top:60px; left:60px"></div>

In Mozilla, this div is displayed properly over a PDF document. But in IE(8, 9, 10) it is displayed below PDF.

Please let me know if I can do something about it.

Fiddle: http://jsfiddle.net/audetwebdesign/Q6nF6/

Michael Rovinsky
  • 6,807
  • 7
  • 15
  • 30
Ashwin
  • 12,081
  • 22
  • 83
  • 117
  • 1
    Does the z-index have any control over the positioning? (i.e. layering above the pdf document). If it's any use, [I did find this](http://stackoverflow.com/questions/593176/div-layer-on-top-of-pdf). – Paul May 22 '13 at 11:01

1 Answers1

1

for absolute positioning to work the parent element must have positioning so make your parent element position: relative;

Haben
  • 95
  • 5