The method
returns the value of the header as a string.
var strCL;
strCL = xmlHttp.getResponseHeader("Content-Length");
In addition to supporting these methods, the XMLHttpRequest object supports a number
of properties, as listed in Table 1-1.
Table 1-1. The Standard Set of Properties for XMLHttpRequest
Property Description
onreadystatechange Specifies the name of the JavaScript function that the XMLHttpRequest
object should call whenever the state of the XMLHttpRequest object
changes
readyState The current state of the request (0=uninitialized, 1=loading, 2=loaded,
3=interactive, and 4=complete)
responseText The response from the server as a string
responseXML The response from the server as XML
status The HTTP status code returned by the server (for example, ???404??? for
Not Found or ???200??? for OK)
statusText The text version of the HTTP status code (for example, ???Not Found???)
CHAPTER 1 ?– INTRODUCING AJAX 11
Using Visual Studio 2005
Throughout this book, you??™ll be using Visual Studio 2005 to develop AJAX applications
using ASP.NET AJAX. Several editions of this application are available to satisfy different
needs.
Pages:
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54