WebSource
view release on metacpan or search on metacpan
WebSource/Parser.pm view on Meta::CPAN
if($a =~ m#[^\w_:\-]#) {
$self->{verbose} and warn "Bad attribute $a detected and removed";
} else {
push @naseq, ($a);
$nattr{$a} = $attr->{$a};
}
}
$self->SUPER::start($tag,\%nattr,\@naseq,$origtext);
}
sub text {
my ($self,$origtext,$iscdata) = @_;
if(!$iscdata) {
$origtext =~ /Sion/ and print "Text : $origtext\n";
if($origtext =~ m/\0/) {
$self->{verbose} and warn "Decected null char\n";
$origtext =~ s/\0//g;
}
if($origtext =~ m/\&\#[0-9]\;/) {
warn "Bad entity detected";
$origtext =~ s/\&\#[0-9]\;//g;
}
}
$self->SUPER::text($origtext,$iscdata);
}
}
our @ISA = ("XML::LibXML");
=head1 NAME
WebSource::Parser - A XML/HTML parser extending XML::LibXML
=head1 DESCRIPTION
( run in 0.573 second using v1.01-cache-2.11-cpan-454fe037f31 )