W3C home > Mailing lists > Public > public-webapps@w3.org > October to December 2012

Re: [XHR] Need to define the behavior when the Window the XHR is created from does not have an associated document

From: Anne van Kesteren <annevk@annevk.nl>
Date: Fri, 14 Dec 2012 20:29:46 +0100
Message-ID: <CADnb78gF+jXMdz6e2Gd6CKpCaN3LD2Z=VoQXHpF9ageLwz5OgQ@mail.gmail.com>
To: Boris Zbarsky <bzbarsky@mit.edu>
Cc: Ian Hickson <ian@hixie.ch>, Jungkee Song <jungkee.song@samsung.com>, public-webapps@w3.org
On Fri, Dec 14, 2012 at 7:59 PM, Boris Zbarsky <bzbarsky@mit.edu> wrote:
> On 12/14/12 1:55 PM, Anne van Kesteren wrote:
>> It seems to depend on whether or not the old Window object still has
>> an associated document. If it still points to the active document the
>> above "would work". If it points nowhere the above cannot work
> Well.  It depends on whether we want to use the old Window or the new one,
> for one thing....

Per Hixie the Document is associated with both the old and the new
Window. Meaning that XMLHttpRequest will function normally even though
XMLHttpRequest != window.XMLHttpRequest. Testing in Opera reveals this
to work fine.

window.onload = function() {
 var x = new XMLHttpRequest;
 x.open("GET", "image", false) // evil

(Written for Live DOM Viewer)

Given this, I think the XMLHttpRequest needs no change, although it
would probably be wise to cover this in the test suite.

Received on Friday, 14 December 2012 19:30:31 UTC

This archive was generated by hypermail 2.3.1 : Friday, 27 October 2017 07:26:50 UTC