Interesting reg exp tricks
<php $reg = "/(\w+) or (\w+)/"; $rep = '${1} and ${2}'; $string = "Jack or Jill"; echo preg_replace($reg, $rep, $string);