title: Login to a website using Jsoup and stay on the site
body: <p>I try to log in here: <a href="http://www.gszi.sulinet.hu/dinaweb/diakok/belepes.jsp" rel="noreferrer">http://www.gszi.sulinet.hu/dinaweb/diakok/belepes.jsp</a>
  with this:</p>
  
  <pre><code>Connection.Response loginForm = Jsoup.connect("http://www.gszi.sulinet.hu/dinaweb/diakok/belepes.jsp")
              .method(Connection.Method.GET)
              .execute();
  
  Document doc = Jsoup.connect("http://www.gszi.sulinet.hu/dinaweb/diakok/belepes.jsp")
              .data("name","myid")
              .data("name","mycode")
              .cookies(loginForm.cookies())
              .post();
  </code></pre>
  
  <p>Afterwards, getting the html of a page which I have to login to see, I realize that I couldn't log in. Is there a way to login and then get the html of pages I have access now? Any link, advice or help appreciated.</p>