What condition do you want to set it true for?
It looks to me like your tests would be better structured:
if($inputfield =~ m/(F|f)(irst)?name/) { $mech->set_fields( $inputfield => $fname); print "matched firstname regex\n"; } elsif ($inputfield =~ /(L|l)(ast)?name/) { $mech->set_fields( $inputfield => $lname); } elsif ($inputfield =~ /(A|a)ddress[123]?/) { $mech->set_fields( $inputfield => $address); } elsif ... } else { $submit="0"; print "Setting submit=0\n"; }
In reply to Re^3: WWW:Mechanize problems
by GrandFather
in thread WWW:Mechanize problems
by stanislav5000
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |