This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class HtmlFilter{ //Version: 3.1 | |
const OPENS = 1; | |
const CLOSES = 2; | |
const SINGLE = 3; | |
public $goodTagsRE = 'i|b|a|em|strong|hr|ul|ol|li|img'; | |
public $goodAttrs = array('href', 'src', 'class', 'alt', 'title'); | |
public $goodProtocolsRE = 'https?|s?ftp|mailto|torrent'; | |
public $defaultProtocol = 'http://'; //prepended to URLs without above protocols |