listToArray()
Posted: Tue Jul 09, 2002 2:04 pm
I would like to convert a comma separated list to an array.
$myList = "value1, value2, value3, ...";
$myArray = listToArray($myList);
I don't see a native function for this, but being inexperienced with PHP, I may have missed it. I could build it with regular expressions, but thought this must be a pretty common function, so I thought I would check here first.
Greg Alton
$myList = "value1, value2, value3, ...";
$myArray = listToArray($myList);
I don't see a native function for this, but being inexperienced with PHP, I may have missed it. I could build it with regular expressions, but thought this must be a pretty common function, so I thought I would check here first.
Greg Alton