title: Posting a html page using c++
body: <p>I'm trying to post a html page using c++. I built a class using the sockets that implements tcpsoketing.
  I checked it and it worked. So i think my problem is in what I send :   </p>
  
  <pre><code>string s = "&lt;!DOCTYPE html&gt;&lt;html&gt;&lt;head&gt;&lt;title&gt;home.html&lt;/title&gt;&lt;/head&gt;&lt;body&gt;&lt;form name='input' action='login.html' method='get'&gt;user name: &lt;input type='text' name='user'&gt;&lt;br&gt;password: &lt;input type='text' name='password'&gt;&lt;input type='submit' value='Submit'&gt; &lt;/form&gt;&lt;/body&gt;&lt;/html&gt;";
  
  string str="POST /home.html HTTP/1.1\r\nHost: 127.0.0.1:22225\r\nUser-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/30.0.1599.66 Safari/537.36\r\nAccept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8\r\nAccept-Language: en-US,en;q=0.8Accept-Encoding: gzip,deflate,sdch\r\n\r\n\r\n\r\nConnection: keep-alive\r\nContent-Type: application/x-www-form-urlencoded\r\nContent-Length: 2048"+s;
  </code></pre>