By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
455,362 Members | 1,354 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 455,362 IT Pros & Developers. It's quick & easy.

Json or XML or custom encoding

P: 39

I am working with web project where I have to send complex data to
servlet, using Ajax.

My question is, which method is the best or easy to implement?

Complex data means:
Javascript objects and some of them arrays. These arrays
contain other objects

Nov 5 '08 #1
Share this Question
Share on Google+
2 Replies

rnd me
Expert 100+
P: 427
ajax uses xml, but json data is much easier and faster to work with in javascript.
Nov 6 '08 #2

Expert Mod 5K+
P: 5,389
i would recommmend JSON since it has less overhead and could be very smart used by JavaScript ... even though it could be that it is not the best choice when you have an application that already uses XML or another encoding and you would have to split the processing logic. but in case you have the choice - then certainly JSON is your best bet :)

kind regards
Nov 6 '08 #3

Post your reply

Sign in to post your reply or Sign up for a free account.