Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

JavaScript AJAX Basics (retiring) AJAX Concepts Introducing AJAX

Why does AJAX use XML?

I just re-watched the intro to AJAX video, and the video mentions that in order to see AJAX on the console you need to enable the ability to see XML HTTP requests. What I'm not understanding is why AJAX is using XML vs. some variant of JS. Isn't AJAX a variant of JavaScript not XML?

1 Answer

Seth Kroger
Seth Kroger
56,405 Points

From MDN: "AJAX stands for Asynchronous JavaScript and XML." XML is just the format of the data being requested/sent. Think of it as a much more generalized version of HTML where you can make up your own tags. Nowadays it's more common to request JSON over XML, but the original name stuck.