I am attempting to "simulate" a button press and form submission with username and password to sign into the website with source below. I have already tried this:
Document con = Jsoup.connect("http://www.twinrinks.com/adulthockey/subs/subs_entry.html")
.data("subs_data1",autoLogInUsername)
.data("subs_data2",autoLogInPassword)
.post();
(autoLogInUsername and autoLogInPassword are String objects)
But that does not seem to want to work correctly. I have read around here on stack overflow, and I have tried many of the suggestions, but I can't seem to get this to work. I'm thinking my problem is either that the form is a GET instead of a POST, or that i'm not doing anything with the submit button (but I don't know how to reference it because it has no name). Thanks for your help!
<html>
<head>
<title>Login Page</title>
<FONT FACE="ARIAL" SIZE="5" color="#FF00FF">Twin Rinks Ice Pavilion, Inc. Attendance & Subs Program<BR></font>
</head>
<body onLoad="document.forms.myform.subs_data1.focus()">
<form name="myform" method="GET" action="subs_entry.php">
Username:<input type=text name=subs_data1 size="70" value="">
(your email address)<br>
Password:<input type=password name=subs_data2 size="25" value=""><br>
<input type=submit value="Login!">
<br><br>Leisure next session
schedule is done.<br>Bronze next session schedule is done.<br>Silver
next session schedule is done<br>Gold
next session schedule is done.<br>Platinum next session
schedule is done.</form>
</body>
</html>