Fixed PHP5.4 preg_replace