WordPress.org

Support

Support » How-To and Troubleshooting » No Smilies in Comments.

No Smilies in Comments.

Viewing 11 replies - 1 through 11 (of 11 total)
  • I should have mentioned that they work in posts, but not comments. Also, I can’t get the threaded comments hack to display correctly, but thts another issue.

    Mine are not working in comments either. All I get are spaces in the html that is output.

    southerngal
    Member

    @southerngal

    I can’t get them to work in comments either, what’s the deal??? I pulled my “clickable smilies” hack until this is fixed.

    Laughinglizard
    Member

    @laughinglizard

    Find this function in your template-functions.php (in your wp-includes 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;
    }
    And replace it with:
    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 = make_clickable($comment_text);
    $comment_text = balanceTags($comment_text,1);
    $comment_text = apply_filters(‘comment_text’, $comment_text);
    $comment_text = convert_smilies($comment_text);
    echo $comment_text;
    }

    Thanks!!

    southerngal
    Member

    @southerngal

    THANK YOU!!! 🙂

    Laughinglizard
    Member

    @laughinglizard

    😀
    Peace

    Thanks

    Add me to the list of people thanking you for that, Mr. Lizard. 🙂

    It looks like this bit of wizardry has made it into 1.0.1. Yay! 😀

    Hmm…still isn’t working for me (in 1.0) even after updating template-functions.php…although comment smilies were being stripped out altogether before this, and now I’m at least seeing the text equivalents.

Viewing 11 replies - 1 through 11 (of 11 total)
  • The topic ‘No Smilies in Comments.’ is closed to new replies.