Your skill will accomplish what the force of many cannot |
|
PerlMonks |
Is this a bug in HTML::Form::Input or am I doing something wrong?by Pug (Monk) |
on Mar 01, 2002 at 00:24 UTC ( [id://148438]=perlquestion: print w/replies, xml ) | Need Help?? |
Pug has asked for the wisdom of the Perl Monks concerning the following question:
Sorry this is kind of long winded. I have a program, acting like a browser, that logs into a server. It needs fill out a form (that is done) and then when the program hits submit, upload a file to the server. I have use HTML::Form to fill out the form and to give the HTML::Form the proper path and file name, which works. But when LWP::UserAgent->request($form->click("submit")) happens I get a 500. The code I wrote is below. $ERROR has in it your basic 500 error page. At $form->click("submit") I did a print $form->click("submit")->as_string(); Which gave me the following output.
Which when you look at the code for LWP::UserAgent It does not do anything special with Content-Disposition. The input that has the name "clientCertReq" is a HTML::Form::TextInput object. But if you look at HTML::Form::TextInput (it is in the HTML::Form file.) The comments below that point say #input/text #input/password #input/file #input/hidden #textarea But there is no code to open a file and add the data from the file to the Content-Disposition field. I have looked for other soluations using HTTP::Request::Common->POST but that seems more work for me considering that LWP::UserAgent->request seems to eventay calls HTTP::Request::Common->POST. So is this a bug or am I doing something wrong? Edit by dws to add <readmore> tag
Back to
Seekers of Perl Wisdom
|
|