Re: str_replace around a character??
| From: | Jay Ess | Date: | Wed, 13 Jul 2011 08:09:45 +0000 |
| Subject: | Re: str_replace around a character?? | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-314032@lists.php.net to get a copy of this message | ||
On 2011-07-13 09:54, Karl DeSaulniers wrote:
$cc = "email1@domain.com ,email2@doamin.com,email3@domain.com , email4@domain.com, "$cc = trim($cc,","); $result = preg_replace('/(\s?)(,)(\s?)/i', ',', $cc);