Exercise: AJAX

In this exercise, you'll use jQuery's $.ajax function to pull in a JSON file and turn it into DOM, using the same functions as we did for the in-page JSON.

The Setup

You can skip this section if you are using Firefox.

If you are not yet running your code from a local server, do that now by following these instructions. We need to do this because of security restrictions on file:// protocol with XMLHttpRequests.

Coding

Go through these steps, and do as many as you can in the time we have:

Make sure that you use your browser developer tools to make debugging easier while working on this. Check for errors, and use console.log() to figure out how far your code makes it, and what the values of your variables are along the way.