In article <2f**************************@posting.google.com >,
ar************@jpmorgan.com shared the illuminating thought...
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.loc ation" 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.
----------------------------------------