ScriptPlazzaon Google+

With following snippet you can remove or replace all special characters from a string.

<?php
$string = "#Scrip!Pläzzä%";
$replace = preg_replace ('/[^\p{L}\p{N}]/u', ' ', $string);

echo $replace;
?>
output: Scrip Pl zz 
 

Leave a Comment

You must be logged in to post a Review.