Hello everyone,
I am using the code in the following website (http://www.adp-gmbh.ch/win/misc/sockets.html#test) that is a ready Socket and Client class for connecting to a website. But in the Client.cpp code, if I put a query for Google instead of the host name in the send() method, I get a bad response.
s.SendLine("GET / HTTP/1.0");
s.SendLine("Host: www.google.com/search?hl=en&q=chair");
s.SendLine("");
does not work, and
s.SendLine("GET / HTTP/1.0");
s.SendLine("Host: www.google.com");
s.SendLine("");
works... And SendLine is just a call to send() in WinSock2.h.
Anyone has any ideas?
THANKS!