title: How can I send a login request to a website?
body: <p>so I want to send a request to log in to a website, how can I do that</p>
  
  <p>I have tried the code bellow:</p>
  
  <pre><code>string formUrl = "https://account.mojang.com/login";
              string formParams = string.Format("email_address={0}&amp;password={1}", "your email", "your password");
              string cookieHeader;
              WebRequest req = WebRequest.Create(formUrl);
              req.ContentType = "application/x-www-form-urlencoded";
              req.Method = "GET";
              byte[] bytes = Encoding.ASCII.GetBytes(formParams);
              req.ContentLength = bytes.Length;
              using (Stream os = req.GetRequestStream())
              {
                  os.Write(bytes, 0, bytes.Length);
              }
              WebResponse resp = req.GetResponse();
              cookieHeader = resp.Headers["Set-cookie"];
  </code></pre>
  
  <p>I get an error at line 9 : "Can not send a body of content with this type of verb."</p>