You may be a little confused.
JSON and AJAX are not any choice.
JSON and XML are choices.
JSON and AJAX are different and largely unrelated, although AJAX often uses JSON, it can just use XML, HTML, or plain text.
Or do you mean X in AJAX (XML)? If so, the arguments for JSON are basically:
- JSON has less payload than the XML equivalent; and
- JSON is easier to handle in Javascript (compare eval'ing a JSON object with the progress of an XML fragment).
Other than that, it is largely a personal preference.
cletus
source share