Try setting store_comments before you parse the file:
my $template_tree = HTML::TreeBuilder->new(); $template_tree->->store_comments(1); $template_tree->parse_file (\*TEMPLATE);
Note: the HTML::TreeBuilder documentation says:
$root->store_comments(value)This determines whether TreeBuilder will normally store comments found while parsing content into $root. Currently, this is off by default.
In reply to Re: finding comments with HTML::Element
by GrandFather
in thread finding comments with HTML::Element
by rwburden
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |