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

Popular posts from this blog

jquery - How can I dynamically add a browser tab? -

node.js - Getting the socket id,user id pair of a logged in user(s) -

keyboard - C++ GetAsyncKeyState alternative -