Perhaps you could give us an example of the text you are trying to parse
that includes a comment that gets passed to the 'comment' event handler, but
doesn't get passed to the 'default' event handler when the 'comment' handler
isn't defined.

A short example script that shows the problem would also be handy.  I'd be
especially interested in seeing all HTML::Parser method calls..
--
Mac :})
** I may forward private database questions to the DBI mail lists. **
----- Original Message -----
From: "Hugo Haas" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, July 07, 2000 3:28 PM
Subject: HTML::Parser bug?


> The man page says about handlers:
>
>        Events
>
>        Handlers for the following events can be registered:
>
>        [..]
>
>        default
>             This event is triggered for events that do not have a
>             specific handler.  You can set up a handler for this
>             event to catch stuff you did not want to catch
>             explicitly.
>
> so I didn't assign any handler to the comment event, thinking default
> would be called:
>
>   $p->handler(default => 'text', 'self, text');
>
> This doesn't do what I was expecting whereas:
>
>   $p->handler(comment => 'text', 'self, text');
>   $p->handler(default => 'text', 'self, text');
>
> this does (with version 3.08 and 3.10).
>
> Is it me not reading the documentation right (in that case, I think that
> it is unclear) or is it a bug?


Reply via email to