in reply to Re^2: WWW::Mechanize and "Bad <select> tag 'input'"
in thread WWW::Mechanize and "Bad <select> tag 'input'"

Well that's just plain bizarre. I don't know how HTML::Form gets the idea that $tag should be "select" since you don't have a single <select> in your HTML. (The warning you're getting is inside a "if ($tag eq 'select')" block and does appear to be designed to detect invalid tags inside a <select> block.)

What version of HTML::Form are you using, btw? The latest on CPAN has a similar line, but not exactly the same:

    warn("Bad <select> tag '$tag' in $base_uri\n") if $verbose;

Is it possible that you're not getting the HTML you think you're getting? Maybe an auth system getting in the way or some other trickery?

-sam

Replies are listed 'Best First'.
Re^4: WWW::Mechanize and "Bad <select> tag 'input'"
by talexb (Chancellor) on Mar 19, 2008 at 19:13 UTC
      What version of HTML::Form are you using, btw?

    Thanks for your persistence .. my version of HTML::Form is 1.49; I see CPAN has 1.054, which I presume is a few versions more recent.

      Is it possible that you're not getting the HTML you think you're getting? Maybe an auth system getting in the way or some other trickery?

    Good questions .. let me dump out the HTML I do get and confirm that's what I posted. Thanks again.

    Alex / talexb / Toronto

    "Groklaw is the open-source mentality applied to legal research" ~ Linus Torvalds

      I don't get that warning, WWW::Mechanize 1.20, HTML::Form 1.49, perl v5.8.7
      perl -S -W mech-dump file:./misc.html POST file:/somescript.pl [somename] referrer=html (hidden readonly) username= (text) <NONAME>=Submit (submit)
Re^4: WWW::Mechanize and "Bad <select> tag 'input'"
by talexb (Chancellor) on Mar 19, 2008 at 19:26 UTC

    Just checked -- by dumping out the contents of the page, as far as WWW::Mech is concerned -- and it's the same as the page that I pasted earlier. There is a timeout that happens after an hour, but my test logs on and immediately tries to get to the web page, so that's not happening here.

    I wonder if that warning will disappear if I disable warnings ..

    Alex / talexb / Toronto

    "Groklaw is the open-source mentality applied to legal research" ~ Linus Torvalds