SendRequest
SendRequest is used to Send the initiated HTTP request. For example, if previously the GetURL method was used a GET request will be sent.
Syntax
SendRequest()
Return value
HTTP Reponse code.
Example
This script will do a GET request and print out the return code:
Function Main
Dim HTTPObj as Object
ip = "www.gfi.com"
port = 80
Set HTTPobj = HTTP.Connect (ip,port)
'Set up the request type
HTTPobj.GetURL("/")
'to pass through the proxy with automatic authentication
'Authentication needs to be set to 1
HTTPobj.Authentication = 1
'Send the GET request
HTTPResponse = HTTPobj.SendRequest()
echo "Result: " + cstr(HTTPResponse)
End Function