Crayon Syntax Highlighter
[resolved] Filters on Comment Content (2 posts)

  1. jamiechong
    Posted 2 years ago #

    It would be nice if you allowed us developers to apply filters on get_comment_content before you parse it for Crayons. Your code ignores it because when you capture your Crayons in the_posts filter, you access $comment->comment_content directly and therefore bypassing any filters other developers may have set. We might want to mangle the comments before your Crayon plugin takes control - perhaps I want to limit some of the settings a user adds to a crayon. I think it would be a simple fix if you just applied filters manually when you grab the content:
    $captures = self::capture_crayons($comment->comment_ID, apply_filters('get_comment_text', $comment->comment_content, $comment), array(CrayonSettings::DECODE => TRUE));


  2. akarmenia
    Plugin Author

    Posted 2 years ago #

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Crayon Syntax Highlighter
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic


No tags yet.