preg_replace vs preg_match

Yes. preg_replace can accept arrays for both what is to be searched for and what to replace it with so that all the replaces can be done with a single call.