logo       

Re: baseURI and XMLHttpRequest: msg#00046

Subject: Re: baseURI and XMLHttpRequest
You maen: wrap the "XMLHttpRequest()" prototype in a singleton.

Doron Rosenberg wrote:

Indeed, this seems to be an issue. Going to file a bug and see what that brings us.

A workaround is to move

        var XmlHttpRequest;
if( navigator.appName == "Netscape" )
        XmlHttpRequest = new XMLHttpRequest();
    else
        XmlHttpRequest = new ActiveXObject( "MSXML2.XMLHTTP.4.0");

out of the function loadXml() and into the global namespace. That then works fine.

Adrian Herscu wrote:

Hi all,

Consider the following scenario:

1) A root window hosts a script function that uses the XMLHttpRequest
object to load XML resources. The script function accepts _relative_
URLs, and it works correctly when invoked from the root window.

2) A child window (loaded from some other path) hosts an event handler that calls the aforementioned script function (through "window.opener" object). Although the "window.document.baseURI" property of the child window points to the same URL as its root window, the function call fails (404 - Object not found).

Tested on Linux/Mozilla1.3 and Win2K/Mozilla1.6a.
Also tested on Win2K/IE6+MSXML4 and it works as expected.

Thanx,
Adrian.

P.S. Test-case attached.





<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

Recently Viewed:
web.pylons.gene...    hurd.l4/2002-10...    kernel.commits....    user-groups.lin...    yellowdog.gener...    java.drools.use...    security.openva...    package-managem...    linux.debian.us...    qnx.openqnx.dev...    genealogy.gramp...    file-systems.if...    voip.wengophone...    tex.context/200...    ietf.smime/2003...    audio.csound.de...    culture.region....    xfree86.devel/2...    mobile.kannel.u...    distributed.con...    education.engli...    org.user-groups...    bug-tracking.gn...    recreation.bicy...   
Home | blog view | USPTO Patent Archive | advertise | OSDir is an inevitable website. super tiny logo

Free Magazines

Cisco News
Receive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business.
subscribe

Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field.
subscribe

The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business.
subscribe

Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company.
subscribe

Total Telecom Total Telecom is "The Economist of the communications industry".
subscribe