I have a JSON, let's say "{\"a b\": 13}".

json_decode() handles it properly. However, then resulting object has
a property composed of two words.

What I did to access this property was the following:

$json = "{\"a b\": 13}";
$decoded = json_decode($json);
$tag = "a b";

However, this seems clumsy. Is there another, nicer way to access
multi-word props in PHP? I suppose there should be, due to the loosely
typed nature of PHP, where everything is a map, but I couldn't find



Fine counsel is confusing, but example is always clear. (Edgar A.
Guest, The Light of Faith)

PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to