Re: splitting string into array
| From: | Marek Kilimajer | Date: | Wed, 29 Sep 2004 13:57:39 +0000 |
| Subject: | Re: splitting string into array | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-198187@lists.php.net to get a copy of this message | ||
blackwater dev wrote:
How can I take a string and create an array? Example, A12B05C45D34 I need to split this into chunks of three A12,B05,C45..etc? Thanks!$chunks = preg_split('/(.{3})/', $str, -1, PREG_SPLIT_NO_EMPTY | PREG_SPLIT_DELIM_CAPTURE);