Support » Plugins » Remove formatting (comment plugin)

  • thornomad



    I am using a comment plugin on my site

    I am using the function that displays some of the text from the most recent comment in a list (and links to the full comment). This works well UNLESS there is any sort of html formatting in the comment …

    For example, if there is a <a href= tag in the beginning of the comment, the function will output the text, plus the beginning of the <a href= tag, but not close the tag … and this causes for some whacky results.

    Where the comment text is added in the function is on this line:

    echo substr($comment->comment_content,0,$length);

    Is there any way to stip whatever content is being pulled of its html tags ?


  • The topic ‘Remove formatting (comment plugin)’ is closed to new replies.