hz, darbojas.
function minus($teksts){
$minus = array("'", "-", "*",);
$teksts = str_replace($minus, "",$teksts);
return htmlspecialchars($teksts);
}
$x = "šeit' '-' **** vajadzētu";
echo $textcontent = minus($x);// šeit vajadzētu
Having a trailing comma after the last defined array entry, while unusual, is a valid syntax.