From: "John Clegg" <[EMAIL PROTECTED]>
> I am trying to figure out how to get ereg_replace / preg_replace to
> replace a match only once.

The fourth parameter to preg_replace() is an integer limit to how many
matches you want to allow. So, if you only want 1 replacement to occur, pass
1. :)

---John Holmes...

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to