Is there an equivalent to outerHTML in Netscape 4?

A

Aron

What I really need to do is determine the source of a frame (in this
case, a PDF) in a different window, close that window, and then launch
a new window with that source, displaying only the PDF. However, when
I try to access the DOM, it tells me that access is disallowed to
scripts from another domain. This strikes me as a bug, since the
pages are in the same domain. If I could just get the HTML source of
the other window, I could parse out what I need, ugly as that is.
Thanks in advance.
 
K

kaeli

What I really need to do is determine the source of a frame (in this
case, a PDF) in a different window, close that window, and then launch
a new window with that source, displaying only the PDF. However, when
I try to access the DOM, it tells me that access is disallowed to
scripts from another domain. This strikes me as a bug, since the
pages are in the same domain. If I could just get the HTML source of
the other window, I could parse out what I need, ugly as that is.
Thanks in advance.

From a frame in the same frameset: top.frames
["framename"].document.location.href

I don't think you can do it from another window unless you already have
a variable that references the frameset window, such as if you'd opened
it from that window. I.E. the frameset window is a child of the window
you're trying to access it from.

As for the domain issue, protocol is included. You can't access https
from http and other such things. It may have a problem because the PDF
is a different security level or something.

Is there some reason you can't just have a button in the window with the
PDF in it to open it sans frames?
<input type="button"
onclick="top.document.location=window.document.location" value="Open
sans frames">

----------------------------------------
~kaeli~
http://www.ipwebdesign.net/wildAtHeart
http://www.ipwebdesign.net/kaelisSpace
Jesus saves, Allah protects, and Cthulhu
thinks you'd make a nice sandwich.
----------------------------------------
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,015
Latest member
AmbrosePal

Latest Threads

Top