I have this string..
'<tag k="addr:country" v="UY"/>'
I want make that string into an array like
array(
"k" => "addr:country",
"v" => "UY"
)
I planning to explode by ' ' and explode it again by charater '=' and form the array, but I dont think that is a good code. I am wondering if there is a better way of extracting the attribute from the string.
Thanks in advance/