fixed: filtering of rich text areas very slow for large content

This commit is contained in:
Graham Knop 2008-12-03 00:32:36 +00:00
parent 314da5621e
commit 4a88e39c21
2 changed files with 2 additions and 1 deletions

View file

@ -64,7 +64,7 @@ sub cleanSegment {
my $html = shift;
my $preserveStyleScript = shift;
my $headers = "";
if ($html =~ s{(.*)<body\b.*?>}{}is && $preserveStyleScript) {
if ($html =~ s{^(.*)<body\b[^>]*>}{}is && $preserveStyleScript) {
my $head = $1;
# extract every link tag
while ( $head =~ m{(<link\b[^>]+>)}isg ) {