Hi,

For JS it is clear that JSON will be faster, but what is the better
choose in Java for Android? I mean, is it JSON parsed faster than XML on
Dalvik?

And for the authentication I used to use PHP sessions and cookies when
developing web pagers.

Will be this also the prefered way to do it with the Android HTTP
client? The other way I am considering is to give the client a token
from the server after authentication and pass it in every POST or GET
request to the server.

This has the disadvantage of having to take care of passing it in every
request, but on the other hand avoiding cookies should made the code
simpler and easier to debug.

Regards,


On 08/06/12 15:59, Chris Mawata wrote:
> There is an HTTP client on Android. When you talk about parsing strings, 
> what structure do you have? There are facilities for handling JSON and
> XML. 
>
> On Friday, June 8, 2012 6:48:22 AM UTC-4, Fran wrote:
>
>> Hi there, 
>>
>> I need to interchange data between my Android app, written in Java using 
>> eclipse, and an Apache HTTP server through some PHP scripts. 
>>
>> What is the best way to do so? 
>>
>> I do not know if there is some bultin functions yet on API that could 
>> make the communication easier than directly using sockets and parsing 
>> strings. 
>>
>> Thanks a lot in advance, 
>>
>>

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to