Clear questions and runnable code get the best and fastest answer |
|
PerlMonks |
checking if form field exists in WWW::Mechanizeby Anonymous Monk |
on Oct 15, 2005 at 17:20 UTC ( [id://500465]=perlquestion: print w/replies, xml ) | Need Help?? |
Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
I have a crawler that works on a dynamic web site. Sometimes certain parts of forms aren't available which causes my script to come to a screeching hault and tell me "No such field 'so and so' at /usr/lib/perl5/site_perl/5.8.4/WWW/Mechanize.pm line 1151 How can I check to see if this form is here with WWW::Mech? I assume I could always parse the HTML to see if the form field exists but that's just ugly. Is there a way to do it inside the module? Thanks!
Back to
Seekers of Perl Wisdom
|
|