changing post-type when posting using webclient

  • Thread starter Thread starter lasabo
  • Start date Start date
L

lasabo

Hi,

I'm trying to log in to a webpage automaticly, the
sourcecode for the page is:

<FORM ACTION="/login_post" METHOD="POST">
<input type="hidden" name="REDIRECT"
value="config.htm"><div align="left">
Password&nbsp; </font><input type="password" name="PWORD"
size="20">
<input type="submit" value="Login">

When I try to post the data using uploadData I send:

REDIRECT=config.htm&PWORD=XXXXX

When I use Ethereal I see that this is the same post that
the Internet Explorer posts. The only difference is that
my program sends a "POST config.htm" header, but the IE
sends "POST /login_post" . I think this may be why my
program cant log in. Does anybody know how I change this?
 
lasabo,

When you are setting the url for the posting, you want to make it so
that it is /login_post not config.htm. The action is the URL that the
contents of the form are to be posted to.

Hope this helps.
 
Back
Top