android - How to GET xml file with request? -


sorry bad english. i've managed how authorization token from question , can't how work xml. documentation says (translating):
contents of /me/ resource:
https://api-yaru.yandex.ru/me/?oauth_token=111111111111111111

answer in xml format
please, explain, how can xml file parse it? need use asynctask?
"dirty" code here: http://pastebin.com/njtiupc5

you need append '&format=json' url response in json format

https://api-yaru.yandex.ru/me/?oauth_token=111111111111111111&format=json 

in case

httpentity entity = resp.getentity(); string jsonstr = entityutils.tostring(entity); jsonobject jsonobj = new jsonobject(jsonstr); 

and xml string

string xml = entityutils.tostring(resp.getentity()); 

if want print it

and ever want. luck ;)


Comments

Popular posts from this blog

basic authentication with http post params android -

vb.net - Virtual Keyboard commands -

css - Firefox for ubuntu renders wrong colors -