Skip to content

Commit

Permalink
Revert "onclick attributes cause errors.So sanitize them."
Browse files Browse the repository at this point in the history
This reverts commit 8d4fec7.
  • Loading branch information
mizzy committed Jan 22, 2012
1 parent 8d4fec7 commit a1f8ec3
Showing 1 changed file with 1 addition and 17 deletions.
18 changes: 1 addition & 17 deletions webiblo.pl
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
use LWP::Simple;
use URI;
use HTML::TreeBuilder::XPath;
use HTML::Scrubber;
use Text::Xslate;
use Image::Resize;

Expand Down Expand Up @@ -155,23 +154,8 @@ sub get_content {
$image->attr('src', $file);
}

my @default = (
1,
{
'*' => 1,
'onclick' => 0,
},
);

my $scrubber = HTML::Scrubber->new(
default => \@default,
);

my $content = $scrubber->scrub($tree->as_XML_indented);
$tree->delete;

open my $out, '>', "out/$file" or die $!;
print $out $content;
print $out $tree->as_XML;
close $out;
}

Expand Down

0 comments on commit a1f8ec3

Please sign in to comment.