]> ruin.nu Git - ndwebbie.git/blobdiff - ND/Web/Include.pm
filter out non printable characters
[ndwebbie.git] / ND / Web / Include.pm
index 367dddb54c7b9d6993b277f048135d5ba3586391..4b9c6295408cff511ee93a215f61a57bae88bc92 100644 (file)
@@ -44,6 +44,7 @@ sub parseMarkup ($) {
                my $tree = BBCode::Parser->DEFAULT->parse($text);
                $text = $tree->toHTML;
        };
+       $text =~ s/[^\x{9}\x{A}\x{D}\x{20}-\x{D7FF}\x{E000}-\x{FFFD}\x{10000}-\x{10FFFF}]//g;
        return $text;
 }