Support » Fixing WordPress » Link problem

Viewing 3 replies - 1 through 3 (of 3 total)
  • I recently ran into this issue as well. The problem is that the comments go through a sanitising feature which takes out malicious content but also filters out some useful parts of URLs in comments. Here is the fix, though I suggest you leave it the way it is for security:
    Find this function inside b2template.functions.php which is inside the b2-include folder:
    function comment_text() {
    global $comment;
    $comment_text = stripslashes($comment->comment_content);
    $comment_text = str_replace(‘<trackback />’, ”, $comment_text);
    $comment_text = str_replace(‘<pingback />’, ”, $comment_text);
    $comment_text = convert_chars($comment_text);
    $comment_text = convert_bbcode($comment_text);
    $comment_text = convert_gmcode($comment_text);
    $comment_text = convert_smilies($comment_text);
    $comment_text = make_clickable($comment_text);
    $comment_text = balanceTags($comment_text,1);
    $comment_text = apply_filters(‘comment_text’, $comment_text);
    echo $comment_text;
    }
    Change it to:
    function comment_text() {
    global $comment;
    $comment_text = stripslashes($comment->comment_content);
    $comment_text = str_replace(‘<trackback />’, ”, $comment_text);
    $comment_text = str_replace(‘<pingback />’, ”, $comment_text);
    $comment_text = convert_chars($comment_text);
    $comment_text = convert_bbcode($comment_text);
    $comment_text = convert_gmcode($comment_text);
    $comment_text = convert_smilies($comment_text);
    $comment_text = make_clickable($comment_text);
    //Made change to comments to make some links work
    $comment_text = balanceTags($comment_text,0);
    $comment_text = apply_filters(‘comment_text’, $comment_text);
    echo $comment_text;
    }

    Thank you..
    I works fine in my comment no. 3 http://www.milpoer.dk/blog/index.php?p=17&c=1#comments but not with comment 4. the link is the same. but i don’t see why there is a different between these two.

    Now it works both places, Thank you..

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Link problem’ is closed to new replies.