in reply to A question about HTML::TokeParser

I suggest you look into a wheel called HTML::Form.

The reason text2 is not being displayed is because you read until the end of file looking for option tags in the inner loop (logic flaw), example:

use HTML::TokeParser; my $p = HTML::TokeParser->new(\q[ <bold> <body> ]); use Data::Dumper; while(defined(my $t = $p->get_tag('bold'))){ print Dumper($t); } my $t = $p->get_token() ; print "no more tokens, see " . ( defined $t ? Dumper($t) : "undef" ); __END__ $VAR1 = [ 'bold', {}, [], '<bold>' ]; no more tokens, see undef

MJD says "you can't just make shit up and expect the computer to know what you mean, retardo!"
I run a Win32 PPM repository for perl 5.6.x and 5.8.x -- I take requests (README).
** The third rule of perl club is a statement of fact: pod is sexy.