This page is Ready to Use

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

send

Summary

Initiates the request defined by the XMLHttpRequest.

Method of apis/xhr/XMLHttpRequestapis/xhr/XMLHttpRequest

Syntax

 .send(data);

Parameters

data

Data-type
any

(Optional)

Object that specifies the body of the message being sent with the request. May be any one of ArrayBuffer, Blob, Document, DOMString, or FormData object types.

Return Value

No return value

Examples

var xhr = new XMLHttpRequest();
xhr.open("GET", "http://localhost/test.xml", true);
xhr.send();

Related specifications

W3C XMLHttpRequest Specification
W3C Working Draft

Attributions