getHTTPResponseHeaders
Map<String, String> scrapeableFile.getHTTPResponseHeaders ( ) (professional and enterprise editions only)
Description
Gets the headers of the HTTP Response as a map, and returns them.
Parameters
This method takes no parameters
Return Value
A Map from header name to header value for the response headers.
Change Log
Version |
Description |
5.5.29a |
Available in professional and enterprise editions. |
Examples
Get the Content-Type header
Map headers = scrapeableFile.getHTTPResponseHeaders();
Iterator it = headers.keySet().iterator();
while(it.hasNext())
{
String next = it.next();
if(next.equalsIgnoreCase("Content-Type"))
session.log("Content-Type was: " + headers.get(next));
}