This page is Almost Ready

Notice: The WebPlatform project, supported by various stewards between 2012 and 2015, has been discontinued. This site is now available on github.

error

Summary

The onerror event occurs when the request could not be completed because of an error.

Overview Table

Synchronous No
Bubbles No
Target dom/Element
Cancelable No
Default action
## Examples

Setting the onerror property.

<script type="text/javascript">
function err()
{
    alert("XDR onerror");
}
...
xdr.onerror = err;

Notes

Remarks

The document can respond to the error, but there is no way to determine the cause or nature of the error. The onerror event does not occur when the ontimeout event occurs. To invoke this event, do one of the following:

  • Cannot invoke.

Event handler parameters

This method has no parameters.

See also

Related pages

  • XDomainRequest
  • Reference
  • onloadonload
  • onprogressonprogress
  • Conceptual
  • XMLHttpRequest Enhancements in Internet Explorer 8

Attributions