title: How to form GET HTTP Request with IP Address
body: <p>When I use the below GET HTTP Request in C, I keep getting a <code>400 Bad Request</code> but it works when I use a string character IP Address (eg: www.wwe.com/index.php):</p>
  
  <pre><code>GET %s HTTP/1.0\r\nHost: %s\r\nConnection: Keep-Alive\r\n\r\n
  </code></pre>
  
  <p>The %s after the GET is replaced with something like this: <code>http://54.236.192.188/index.php</code> and the Host value is provided by a hostent struct's h_name string value.</p>
  
  <p>So a request looks like this: </p>
  
  <pre><code>GET http://54.236.192.188/index.php HTTP/1.0
  Host: ec2-54-236-192-188.compute-1.amazonaws.com
  Connection: Keep-Alive
  </code></pre>
  
  <p>What am I doing wrong here?</p>