From http://www.w3schools.com (Copyright Refsnes Data)
Complete XMLHttpRequest Object Reference
The getResponseHeader() method gets a string containing a specific response header of the XMLHttpRequest object.
A response header contains file information like length, server-type, content-type, date-modified, etc.
| xmlHttp.getResponseHeader(header) |
| Parameter | Description |
|---|---|
| name | A string that specifies the name of the header to get. Use the getAllResponseHeaders() method to find the possible header names for the specific document. |
The following code outputs the "Content-Length" header in a HTML element with id="header":
Example
Output:
Try it yourself » |
Complete XMLHttpRequest Object Reference
From http://www.w3schools.com (Copyright Refsnes Data)