Codice PHP:
$AllowableHTML = array(
'a' => array('href' => 1, 'target' => 1, 'title' => array('minlen' => 4, 'maxlen' => 120)),
'b' => array(),
'blockquote' => array(),
'br' => array(),
'center' => array(),
'div' => array('align' => 1, 'class' => 1, 'id' => 1, 'style' => array('font-family' => 1, 'color' => 1, 'width' => 1, 'height' => 1)),
'em' => array(),
'font' => array('face' => 1, 'style' => 1, 'color' => 1, 'size' => array('minval' => 1, 'maxval' => 7)),
'h1'=>array(),
'h2'=>array(),
'h3'=>array(),
'h4'=>array(),
'h5'=>array(),
'h6'=>array(),
'hr' => array(),
'i' => array(),
'img' => array('alt' => 1, 'src' => 1, 'hspace' => 1, 'vspace' => 1, 'width' => 1, 'height' => 1, 'border' => 1, 'align' => 1),
'li' => array(),
'ol' => array(),
'p' => array('align' => 1, 'class' => 1),
'pre' => array('align' => 1),
'span' =>array('class' => 1, 'style' => array('font-family' => 1, 'color' => 1)),
'strong' => array(),
'strike'=>array(),
'sub'=>array(),
'sup'=>array(),
'table' => array('align' => 1,'bgcolor' => 1, 'border' => 1, 'cell' => 1, 'width' => 1, 'cellspacing' => 1, 'cellpadding' => 1),
'td' => array('align' => 1,'bgcolor' => 1, 'width' => 1, 'valign' => 1, 'height' => 1, 'rowspan' => 1, 'colspan' => 1 ),
'tr' => array('align' => 1),
'tt'=>array(),
'u' => array(),
'ul' => array(),
);
Spero che sia utile a qualcuno