]*?)>/isU", //Filter

Home  >  Article  >  Backend Development  >  html color code php filters dangerous html codes

html color code php filters dangerous html codes

WBOY
WBOYOriginal
2016-07-29 08:40:181265browse

#HTML posted by users, filter dangerous code

Copy code The code is as follows:


function uh($str)
{
$farr = array(
"/s+/", //Filter excess whitespace
"/<(/?)(scripti?framestylehtmlbodytitlelinkmeta?%)([^>]*?)>/isU", //Filter