Re: [PHP] Re: Question about string replace -PHP

2002-05-14 Thread Jason Wong
On Wednesday 15 May 2002 05:20, Josh & Valerie McCormack wrote: > I didn't ask the question about this, but I have a related issue. I'm > trying to do a replace, and am using str_replace, but the outcome is not > what I expected. > > Here's my code: > > $fp = fopen("new_data.csv", "r"); > $te

[PHP] Re: Question about string replace -PHP

2002-05-14 Thread Josh & Valerie McCormack
I didn't ask the question about this, but I have a related issue. I'm trying to do a replace, and am using str_replace, but the outcome is not what I expected. Here's my code: Here's the text file it's working on: John Smith Peter Cooper Mike Brown Lisa Crow Here's the outcom

[PHP] Re: Question about string replace -PHP

2002-05-13 Thread Bram van Leur
Replacing a constant string by another constant string works easily with str_replace (http://www.php.net/str_replace). More advanced replacements (with dynamic parts for example) can be replace using Regular expressions (look that up in the Manual, it's quite complex). Could give an example of