Version 1, last updated by Johan Janssens at 18 Apr 17:37 UTC
HTML Text Filter
By default, the field will be filtered using it's type, eg VARCHAR fields are filtered using lib.koowa.filter.string, INT fields using koowa:filter.integer, etc.
You can override that to use a different filter, such as koowa:filter.html. The easiest place to do that is to use annotations in the field comment in your db schema definition:
`description` text NULL COMMENT '@Filter("html")',
You can even have multiple filters:
@Filter("html, tidy")
(Note: The Tidy filter will do nothing if the Tidy library is not installed.)
It gets really interesting if you create your own filters:
@Filter("com://admin/foo.filter.serialnumber")
and in administrator/components/com_foo/filters/serialnumber.php:
class ComFooFilterSerialnumber extends KFilterAbstract
{
protected function _validate($value) {
// return true if the value is a valid serialnumber
}
protected function _sanitize($value) {
// return a cleaned up version of $value
}
}