O'Reilly logo
  • Melinda Ralston thinks this is interesting:

str_replace('a', 'b', 'a1a1a1', $a);

From

Cover of Zend PHP 5 Certification Study Guide

Note

$a should be by reference

str_replace(‘a’, ‘b’, ‘a1a1a1’, &$a);