Re: [PHP] Removing a comma from a form field

2003-02-13 Thread Rick Emery
$thestr = str_replace(",","",$thestring); - Original Message - From: "Ben C." <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Thursday, February 13, 2003 12:13 PM Subject: [PHP] Removing a comma from a form field I'm trying to update a

Re: [PHP] Removing a comma from a form field

2003-02-13 Thread Leif K-Brooks
If the comma is all you have to worry about, you don't need regex. Use www.php.et/str-replace. Ben C. wrote: I'm trying to update a field which contains a $USD figure. But when I update it as 200,000 it become 200. I need to take out the comma. Is using ereg_replace function the best way of

[PHP] Removing a comma from a form field

2003-02-13 Thread Ben C .
I'm trying to update a field which contains a $USD figure. But when I update it as 200,000 it become 200. I need to take out the comma. Is using ereg_replace function the best way of doing so? What do you think. Thanks, Ben -- PHP General Mailing List (http://www.php.net/) To unsubscrib