I have this:
$strVar = \"key value\";
And I want to get it in this:
array(\'key\'=>\'value\')
I tried
Don't believe this is possible in a single operation, but this should do the trick:
list($k, $v) = explode(' ', $strVal); $result[ $k ] = $v;