I can see how you can take part of a string, but only 1 part. Like if you take a part of a string where a "," is. But what if the string holds 5 commas, and you want to make 5 substrings ending each at the next comma. How do you do this? And I can't use the indexed postition because the lenght between the commas will vary. Is there a way to do this?
use the explode() function:
<? $string = 'This,string,has,bunch,of,commas'; $string_array = explode (',', $string); ?>
$string_array now has all the comma separated elements
Ya, that makes sense. 🙂 Thanks.