I get the below dump from an xml URL
I am assigning elements of this to dump to php varibles.
using the following method.
$latitude = $xml->Result->Latitude;
$longitude = $xml->Result->Longitude;
The problem is I also need to asign "warning" from the below xml dump to varible
but the following to methods fail.
$waring = $xml->Result->warning;
$warning = $xml->@attributes->warning;
Can anyone shed some light on this??
impleXMLElement Object
(
[Result] => SimpleXMLElement Object
(
[@attributes] => Array
(
[precision] => city
[warning] => The exact location could not be found. Here is the center of the ZIP code.
)
[Latitude] => 40.789859
[Longitude] => -73.406130
[Address] => SimpleXMLElement Object
(
)
[City] => Melville
[State] => NY
[Zip] => 11747
[Country] => US
)
)