XMLHttpRequest changes for Gecko1.8

  • Revision slug: XMLHttpRequest_changes_for_Gecko1.8
  • Revision title: XMLHttpRequest changes for Gecko1.8
  • Revision id: 172985
  • Created:
  • Creator: DarinFisher
  • Is current revision? No
  • Comment /* Overview */

Revision Content

Overview

This document describes some of the changes that have been made to Gecko's XMLHttpRequest implementation since version 1.7 (i.e., the version of Gecko that shipped with Firefox 1.0). These changes only applie to XUL extensions and XUL applications. They do not apply to web applications.

Details

Changes to XMLHttpRequest.send

If you pass a nsIInputStream instance to the send method, then it must no longer include Content-Length and Content-Type headers at the beginning of the stream. Instead, the Content-Length header will be inferred from the length of the stream, and the Content-Type header must be specified manually by calling the setRequestHeader method. These requirements are more fully described here.

Changes to XMLHttpRequest.onreadystatechange

This attribute now has a type of nsIOnReadyStateChangeHandler instead of nsIOnReadystatechangehandler.

Revision Source

<h3 name="Overview"> Overview </h3>
<p>This document describes some of the changes that have been made to Gecko's
XMLHttpRequest implementation since version 1.7 (i.e., the version of 
Gecko that shipped with Firefox 1.0).  These changes only applie to XUL extensions
and XUL applications.  They do not apply to web applications.
</p>
<h3 name="Details"> Details </h3>
<h4 name="Changes_to_XMLHttpRequest.send"> Changes to XMLHttpRequest.send </h4>
<p>If you pass a nsIInputStream instance to the send method, then it must no
longer include Content-Length and Content-Type headers at the beginning of
the stream.  Instead, the Content-Length header will be inferred
from the length of the stream, and the Content-Type header must be specified
manually by calling the setRequestHeader method.  These requirements are
more fully described <a class="external" href="http://lxr.mozilla.org/mozilla1.8/source/extensions/xmlextras/base/public/nsIXMLHttpRequest.idl#213">here</a>.
</p>
<h4 name="Changes_to_XMLHttpRequest.onreadystatechange"> Changes to XMLHttpRequest.onreadystatechange </h4>
<p>This attribute now has a type of nsIOnReadyStateChangeHandler instead of
nsIOnReadystatechangehandler.
</p>
Revert to this revision