Re: FF3 error when evaluating a cross domain XPath

andywatts <[email protected]>
Newsgroups gmane.comp.mozilla.devel.dom
Organization http://groups.google.com
Message-ID <74249531-371e-4c19-8936-e3958eecb499@k36g2000pri.googlegroups.com>
Here's a complete example that works on FF2 and throws the above error
on FF3.

  <html>
    <head>
      <script>
        function crossFrameDomainXpath() {
 
netscape.security.PrivilegeManager.enablePrivilege("UniversalBrowserRead");
          var d = frames['bottom'].document;
          var t = d.evaluate("//h1/text()", d, null,
XPathResult.STRING_TYPE, null);
          alert(t.stringValue);
        }
      </script>
    </head>

    <body style='margin:0px;'>
      <div height='35%'>
        <h1>h1</h1>
        This frame is localhost <br />
        <INPUT type="button" value="read xpath from bottom iframe"
onClick="crossFrameDomainXpath();"><br />
      </div>
      <iframe src="http://w3schools.com/xpath/default.asp" id='bottom'
name='bottom' height='80%' width="100%"> </iframe>
    </body>
  </html>

Any pointers greatly appreciated.
Andy
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.