liran
14 years agoVisitor
[SOLVED] Async HTTP requests
Hello
I am trying to make an Asynchronous HTTP request by his code:
http = CreateObject("roUrlTransfer")
port = CreateObject("roMessagePort")
http.SetPort(port)
http.SetUrl("http://mysite.com") ' should return response in up to 30 seconds.
' SSL certicate, a must for HTTPS addresses !
http.SetCertificatesFile("common:/certs/ca-bundle.crt")
rsp = http.AsyncGetToString()
message = wait(0,port)
print message.GetResponseCode()
print message.GetString()
print message.GetFailureReason()
And it fails:
-28
Connection time-out
What is the reason for this ?
Thanks
I am trying to make an Asynchronous HTTP request by his code:
http = CreateObject("roUrlTransfer")
port = CreateObject("roMessagePort")
http.SetPort(port)
http.SetUrl("http://mysite.com") ' should return response in up to 30 seconds.
' SSL certicate, a must for HTTPS addresses !
http.SetCertificatesFile("common:/certs/ca-bundle.crt")
rsp = http.AsyncGetToString()
message = wait(0,port)
print message.GetResponseCode()
print message.GetString()
print message.GetFailureReason()
And it fails:
-28
Connection time-out
What is the reason for this ?
Thanks