I am sending http requests using this code :
It works well for most of the http websites, but when I try to get this url "http://www.cplusplus.com/"
the webserver performs a 301 redirection to the same url.
Isn't the webserver supposed to provide a new url in the 301 http headers? What am I doing wrong?
Thanks a lot!!
Last edited on
I found the solution, the get request should be like this :
"GET / HTTP/1.0\r\nHost: www.cplusplus.com\r\n\r\n\r\n"
All the best!