I have a string that is divided by "," and now I want to take the string into array.
$text = "aaa, bbb, ccc"
$textArray = explode(",", $text);
// -> array("aaa","bbb","ccc)
But, I what this string to like this.
// -> array("name" => array("aaa", "bbb" ,"ccc"))
Is there any php method to change the string into array like the above?
if not, what is the best way to implement this?
Thanks in advance:)