replace preg_replace by preg_replace_callback