|
Posted by amit on July 3, 2008, 10:11 pm
Please log in for more thread options
hello group,
I need to extract information from an XML file (http://
wurfl.sourceforge.net/wurfl.xml). Now, using following function I'm
able to read the user_agent's value:
$devices = $xml->xpath('devices/device/@user_agent');
But when I try to read "Capability" element vlaue which is "Audivox" I
don't get anything. or if I try to read "model_name" it will return
nothing!
$capability = $xml->xpath('devices/device/group/capability/
@value');
How should I address value="Audiovox" ?
Thanks.
A block sample of the XML I'm reading.
<devices>
<device user_agent="AUDIOVOX-CDM180" actual_device_root="true"
fall_back="generic" id="audiovox_cdm180_ver1">
<group id="product_info">
<capability name="brand_name" value="Audiovox"/>
<capability name="model_name" value="CDM-180"/>
</group>
</device>
</devices>
|