Boy am I really tired fighting MT on comments content.
Even after I disable ALL plugins, and turn off encoding, convertings, etc. MT STILL strips out a less than-text-greater than content even though it’s NOT HTML tags:


This is < this and > that.

becomes this:

This is that.

Yet another prime example of why to never use RegEx to filter out HTML.
I suspect this is the reason:

sub remove_html {
    my($text) = @_;
    $text =~ s!<[^>]+>!!gs;
    $text =~ s!<!<!gs;

All I want it to take a submitted comment, xml encode the CONTENT, not the tags, then add P and BR tags where appropriate. Apparently this is a tall order for multiple plugins.

Maybe it’s time to roll my own using HTML::Tidy and some quick newline replacements.

See more posts about: wtf | All Categories