java - Parse xml in titanium -
i have response data server. need extract resultant content value xml.
<?xml version="1.0" encoding="utf-8"?> <soap:envelope xmlns:xsi="http://www.w3.org/2001/xmlschema-instance" xmlns:xsd="http://www.w3.org/2001/xmlschema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"> <soap:body> <response xmlns="http://tempuri.org/"> <result>token1234567890</result> </response> </soap:body> </soap:envelope>
i tried getelementsbytagname('response').text;
how can element content result token1234567890
?
replace
getelementsbytagname('response').text;
with
getelementsbytagname('response').innerxml;
it's xml document.
Comments
Post a Comment