Force balanced tags in comments. Props Nazgul. fixes #2714

git-svn-id: https://develop.svn.wordpress.org/trunk@3963 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan Boren 2006-07-04 22:09:44 +00:00
parent b26470e9e9
commit d2f42f1d12
2 changed files with 4 additions and 0 deletions

View File

@ -42,6 +42,7 @@ add_filter('comment_url', 'clean_url');
add_filter('comment_text', 'convert_chars');
add_filter('comment_text', 'make_clickable');
add_filter('comment_text', 'force_balance_tags', 25);
add_filter('comment_text', 'wpautop', 30);
add_filter('comment_text', 'convert_smilies', 20);

View File

@ -505,6 +505,9 @@ function balanceTags($text, $is_comment = 0, $force = false) {
return $newtext;
}
function force_balance_tags($text) {
return balanceTags($text, 0, true);
}
function format_to_edit($content, $richedit = false) {
$content = apply_filters('format_to_edit', $content);