Results 1 to 2 of 2
- 03-28-2008, 10:26 PM #1
Member
- Join Date
- Mar 2008
- Posts
- 3
- Rep Power
- 0
simulate form type=button press with java application
I made a website that uses html and javascript to require log in.
Now i wanted to make a Java application to log in ... instead of using a browser
with a browser you would enter your name in text field and click Login
I use HTTPClient Emulating HTML Forms
now i use NVPair to send the form data for the text field
but it just sits there
i am thinking my problem is: I am not pressing the button
I don't know how to set up a NVPair to simulate the button press
I use InputStream and BufferedReader to read the page
When i do that i seem to get the html code sent to me
When you log in you get to a page that says you are in
If i get the html code that says YOUAREIN i would know it worked
but i am only getting the html code for the login page
so i am thinking i am just filling out the form and not submitting it
- 03-29-2008, 06:28 AM #2
Member
- Join Date
- Mar 2008
- Posts
- 3
- Rep Power
- 0
ok now i am using apache HttpClient
i am getting same results
i submit the form data
and get response of null
they say something about how you need to check cookie to see if logon worked
but my method of log on is just a html form with javascript that if you log on correct you get directed to a new site
... don't think cookies are even involved
so i was hoping i could send the log on data ... then read the resulting page but what i read is NULL
Similar Threads
-
Java Control Panel not saving changes when I press OK
By RebelScum in forum New To JavaReplies: 0Last Post: 03-21-2008, 04:22 PM -
Java Search Form
By djcottrell in forum New To JavaReplies: 1Last Post: 12-28-2007, 07:47 PM -
simulate message box
By pablitohh in forum New To JavaReplies: 1Last Post: 12-05-2007, 04:52 PM -
Adding EXIT button on MIDlet form
By Java Tip in forum Java TipReplies: 0Last Post: 11-22-2007, 10:13 AM -
Press any key to continue/press enter
By JT4NK3D in forum New To JavaReplies: 1Last Post: 11-17-2007, 09:27 PM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks