W3C home > Mailing lists > Public > public-webapi@w3.org > July 2007

Re: [XHR2] overrideMimeType

From: Alexey Proskuryakov <ap-carbon@rambler.ru>
Date: Mon, 30 Jul 2007 14:10:28 +0400
To: Jonas Sicking <jonas@sicking.cc>, Maciej Stachowiak <mjs@apple.com>, Web APIs WG <public-webapi@w3.org>
Message-ID: <C2D3A1D4.3A706%ap-carbon@rambler.ru>

On 7/30/07 12:21 AM, "Jonas Sicking" <jonas@sicking.cc> wrote:

>> If XHR2 offers responseBody with a raw byte array of some kind, it will
>> be required for implementations to keep the raw bytes around anyway.
> Yep. Though it still seems weird to me that responseText would change
> when .overrideMimeType is changed. How do you guys deal with this situation?

  Currently, we only honor MIME type (not charset) change after the response
bytes start to arrive, and only if responseXML hasn't been accessed yet.

Document* XMLHttpRequest::getResponseXML() const
    if (m_state != Loaded)
        return 0;

    if (!m_createdDocument) {
// ...if XML MIME type, create a Document from an already decoded response

        m_createdDocument = true;

    return m_responseXML.get();

  I also expect that some Dashboard content may easily break if overriding
MIME type after send() stops to work.

- WBR, Alexey Proskuryakov
Received on Monday, 30 July 2007 10:11:08 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:16:24 UTC