All,

In using str_replace, I glanced at the manual and found that it can take arrays for it's arguments. Great! I thought that I could have a single search string, an array of replacement vars, and no subject. It would then replace each successive instance of the search string with the next element in the replacement array.

Sadly this is not the case.

Anyone have any recommendations on how to go about this? Best idea using p/ereg_replace? Or just a loop system in which I replace the first instance of the string each time?

I'm not great at p/ereg yet, anyone have any pointers?

Cheers,
Wes


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

Reply via email to