<?php $fullName = 'Foo!"bar" Baz ø hello!<strong>poop</strong>'; $fullName = filter_var($fullName, FILTER_CALLBACK, ['options'=>function($value) { $value = trim($value); // strip tags $value = strip_tags($value); // remove double quotes $value = preg_replace('/["<>\{\}\[\]]+/', '', $value); return $value; }]); echo "$fullName\n";
You have javascript disabled. You will not be able to edit any code.