XML HTTP Request object.
AW.HTTP.Request is a simple wrapper around XMLHttpRequest class in Mozilla or XMLHTTP ActiveX in IE (it also uses native XMLHttpRequest class in IE7). It is intended as a base class for CSV and XML data sources but could be used for standalone AJAX requests as well.
var obj = new AW.HTTP.Request;
| async | Indicates whether asynchronous download is permitted. |
| namespace | Allows to specify namespaces for use in XPath expressions. |
| parameter | Allows to specify the request arguments/parameters. |
| password | Sets or retrieves the password. |
| requestData | Allows to send data with the request. |
| requestHeader | Sets HTTP request header. |
| requestMethod | Specifies HTTP request method. |
| responseHeader | Returns HTTP response header (for example "Content-Type"). |
| responseText | Returns response text. |
| responseXML | Returns response XML. |
| URL | Sets or retrieves the remote data URL. |
| username | Sets or retrieves the user name. |
| clone | Creates an object clone. |
| defineProperty | Creates get/set methods for the property. |
| getAsync | Returns async property |
| getPassword | Returns password property |
| getProperty | Returns property value. |
| getRequestData | Returns requestData property |
| getRequestMethod | Returns requestMethod property |
| getResponseHeader | Returns responseHeader property |
| getResponseText | Returns responseText property |
| getResponseXML | Returns responseXML property |
| getURL | Returns URL property |
| getUsername | Returns username property |
| init | Initializes the object. |
| isReady | Returns true if the model data is available. |
| request | Sends the request. |
| response | Allows to process the received data. |
| setAsync | Sets async property |
| setNamespace | Sets namespace property |
| setParameter | Sets parameter property |
| setPassword | Sets password property |
| setProperty | Assigns property value. |
| setRequestData | Sets requestData property |
| setRequestHeader | Sets requestHeader property |
| setRequestMethod | Sets requestMethod property |
| setResponseText | Sets responseText property |
| setResponseXML | Sets responseXML property |
| setTimeout | Calls the function after the specified delay. |
| setURL | Sets URL property |
| setUsername | Sets username property |
| toString | Converts object to string. |
var req = new AW.HTTP.Request;
req.setURL('<url>');
req.response = function(text) {
alert(text); // do something with response here
};
req.request();