I'm looking at HTML::TokeParser. It expects a scalar with a filename or a reference to a scalar containing the data to parse.
This works fine: my $html; if (@ARGV) { # get filename for TokeParser $html = shift; } else { my @html = <>; $html = \(join '', @html); # pass scalar ref to module } Unless there is no input at all; then the script hangs. So I tried this: my $html; if (@ARGV) { # get filename for TokeParser $html = shift; } elsif (my @html = <>) { $html = \(join '', @html); # pass scalar ref to module } else { die "Usage '$0 [filename]' or 'datasource | $0'\n"; } ...with the same result. -K -- Kevin Pfeiffer International University Bremen -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]