Forum Thread: How to Load Html Content from C/C++

I want to load html content from in c/c++ without curl, what would the GET request look like? I connected on port 80(not https).

This is what I tried --> 'GET /user HTTP/1.1' but it didnt load the html, got a 400 bad request instead.
HTTP/1.1 400 Bad Request
Date: Fri, 29 Jan 2016 10:46:16 GMT
Server: Apache
Content-Length: 226
Connection: close
Content-Type: text/html; charset=iso-8859-1

<title>400 Bad Request</title>
<h1>Bad Request</h1>
<p>Your browser sent a request that this server could not understand.<br />

Join the Next Reality AR Community

Get the latest in AR — delivered straight to your inbox.

3 Responses

It's apparently malformed syntax, do you know what a full GET request looks like?

Check section 5.2 in the link to the RFC (the one in my original reply)

Share Your Thoughts

  • Hot
  • Active