here is how I would do it....
$badwords = array('@%@@!', '!@@#$%');
$userwords = explode(' ', str_to_lower($textfield));
$result = array_intersect($userwords, $badwords);
if(sizeof($result) > 0) {
print 'naughty, naughty';
} else {
print 'nice and clean';
}