Replace deprecated method preg_replace with /e modifier