Welcome! » Log In » Create A New Profile

HtmlPurifier as ZendFramework 2 filter

Posted by Jaimie 
HtmlPurifier as ZendFramework 2 filter
November 21, 2015 01:44AM

Im using HtmlPurifier as a ZendFramework 2 Filter. Works rather nice I know there is a better way to autoload the HtmlPurifier class but not sure, maybe some one chime in??


Another Issue
November 21, 2015 01:45AM

Another issue is if the filter only has say script to strip out it returns an empty value and causes the form to have Validation error if you set field to required and use NotEmpty validator. This also places the script tag back in the Textarea and the JavaScript can be executed. Not exactly the behavior I want.

I set up the filter and validation this way: http://pastebin.com/LkjwT3Wp

Re: Another Issue
November 21, 2015 06:24PM

Sorry, I don't know anything about ZendFramework 2 and can't really help you here. Perhaps the ZF people would know more about how to setup filters.

Sorry, you do not have permission to post/reply in this forum.