This textbook is available atAmazon.com Logo
JavaScript: The Web Warrior Series 6th Edition

JavaScript: The Web Warrior Series (6th Edition)

Book Edition6th Edition
Author(s)Vodnik
ISBN9781305078444
PublisherCengage
SubjectComputer Science
Chapter 11, Introduction to Ajax, Short Quiz, Exercise 1
Page 752

Name two data formats that can be used with Ajax.

Explanation

  • XML is a data interchange format used to exchange web data between server and client. Javascript or any other client-side scripting language is used to read the data embedded in the XML file.
  • JavaScript objects are represented as strings using JSON. JSON is used in data exchange between client and server. Ajax can use JSON instead of XML in order to facilitate data interchange.

Nowadays Ajax uses JSON format compared to XML due to its compact notation and improved readability.

Verified Answer

XML (eXtensible Markup Language) and JSON (JavaScript Object Notation)

How would you rate this answer and explanation?
Did you like this example?
Subscribe for full access
Page 752