• I hope someone can help me out with this:

    I noticed that comment_text() is removing empty line breaks from my comments and I thought that I could simply add them again with
    nl2br(comment_text()
    Unfortunately, that didn’t do the trick! 🙁

    I then went ahead and used nl2br(get_comment_text()) instead but that one won’t convert smilies. This I only could archive by adding 1 more line of code to the default_filters.php within the wp-includes folder:
    add_filter( 'get_comment_text', 'convert_smilies', 20 );

    The above works ok and does what I want it to to, except, I don’t want to modify core script files. Can anybody help me getting this done in another way?

    BTW: I already tried adding add_filter( ‘get_comment_text’, ‘convert_smilies’, 20 ); directly to my functions.php but that had no effect at all.

The topic ‘comment_text | get_comment_text problem’ is closed to new replies.