Is there any way to make this input:
|
testing==one two three
|
setting==more testing
|
and get something like this
array['testing'] = "one two three";
array['setting'] = "more testing"
Right now, I’ll just blow up the lines and set up an array with a numbered index, but I would like the user to be able to enter elements in any order and be able to use the array with the keys from the first value.
function get_desc_second_part(&$value) {
list(,$val_b) = explode('==',$value);
$value = trim($val_b);
}
Thank!
source
share