PDA

View Full Version : pdfs, iframes and floating images


Frank
05-15-2003, 02:29 PM
I'm not sure if this was the right place to ask this, because it may need javascript to work.
Anyway here is my problem, I have a htm doc that has an iframe in it and it displays a pdf, there is also a div that contains a close this window image. I would like to have the close window image float on top of the pdf but I can seem to get it to work. Any ideas?

<html>
<head>
<title>Untitled Document</title>
<style TYPE="text/css">
#back {position: absolute; top: 5; left: 5; }
</style>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>

<body background="image.jpg" >
<div id="back" align="center">
<a href="javascript:window.close()"><img src="close.jpg" border="0"></a></div>
<iframe name="info" src="info.pdf" style="position: absolute; top:55px; left:5px; width: 725px; height: 390px;" scrolling="auto" frameborder="0" >
</iframe>
</body>
</html>

I have tried a couple of floating image scripts that I found on javascriptkit.com but they don't work in this situation.

Roy Sinclair
05-15-2003, 04:51 PM
You're running into a fundamental problem, you can't readily place content over plugins (and some types of form fields). Some browsers give you more control than others but none of the browsers give you complete freedom so right now the answer is that this simply isn't possible.

Frank
05-15-2003, 06:05 PM
Oh, well I guess I'll just have to be happy with what I got.

Thanks, anyway

shlagish
05-16-2003, 01:48 AM
Why don't you put that image in the pdf file itself?

Frank
05-16-2003, 01:57 PM
I could put the image in the pdf, no problem.

Except that I want it to be on the screen at all times.

If it was in the pdf, and the people reading it need to scroll down to view the rest of the document the image will move up with the rest of the text and off the screen. Which is not what I want.:(