W3C home > Mailing lists > Public > public-webapi@w3.org > September 2006

Re: XMLHttpRequest test suite suggestion

From: Anne van Kesteren <annevk@opera.com>
Date: Thu, 21 Sep 2006 19:05:56 -0000
To: "Boris Zbarsky" <bzbarsky@mit.edu>
Cc: "Web APIs WG (public)" <public-webapi@w3.org>
Message-ID: <op.tf8sn6d664w2qv@id-c0020.emi.ac.ma>

On Fri, 21 Apr 2006 22:35:02 -0000, Boris Zbarsky <bzbarsky@mit.edu> wrote:
> If I follow correctly, relative URIs passed to open() should be resolved  
> relative to caller (whatever that means; more on that in a separate  
> mail). That's not actually precisely what Gecko does right now; probably  
> a bug in Gecko.

I think you saw that we changed this to be more compatible with Internet  
Explorer. Basically, from the window you contruct the object in you take  
the window.document.baseURI property and somehow store that on the object  
to resolve URIs against.


> In particular, if you have documents A and B at two different URIs that  
> can talk to each other:
>
> 1)  Document A creates an XMLHttpRequest object
> 2)  Document A sets an onreadystatechange listener on it.
> 3)  Document B calls open()
>
> the base URI will be document A as far as I can tell from the code.   
> Worth adding a test to the test suite for this and similar things where  
> two different windows both work with the same XMLHttpRequest object.

   http://tc.labs.opera.com/apis/XMLHttpRequest/open/001.htm
   http://tc.labs.opera.com/apis/XMLHttpRequest/open/002.htm
   http://tc.labs.opera.com/apis/XMLHttpRequest/open/003.htm
   http://tc.labs.opera.com/apis/XMLHttpRequest/open/004.htm
   http://tc.labs.opera.com/apis/XMLHttpRequest/open/005.htm
   http://tc.labs.opera.com/apis/XMLHttpRequest/open/006.htm
   http://tc.labs.opera.com/apis/XMLHttpRequest/open/007.htm
   http://tc.labs.opera.com/apis/XMLHttpRequest/open/008.htm
   http://tc.labs.opera.com/apis/XMLHttpRequest/open/009.htm
   http://tc.labs.opera.com/apis/XMLHttpRequest/open/010.htm

I welcome other variants to this story.


-- 
Anne van Kesteren
<http://annevankesteren.nl/>
<http://www.opera.com/>
Received on Thursday, 21 September 2006 19:07:02 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 8 January 2008 14:18:55 GMT