Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

JavaScript

AJAX Basics: Stage 3, Challenge Task 2 or 2

The first argument to the $.get() method is a URL to a resource. In this case you want to load the 'footer.html' file, so pass that as the argument.

$.get('app.js', "footer.html");

This is WRONG. Please tell me why. The other things I've been trying are just as wrong.

I am kicked back with a "' Bummer! You need to pass the name of the file: "footer.html". That file is in the same folder as the index.html page, so just provide the name of the file within quotes. '"

3 Answers

Hey Evan,

When you're doing Challenges, try to do exactly as it tells you to do. It tells you: "The first argument to the $.get() method is a URL to a resource. In this case you want to load the 'footer.html' file, so pass that as the argument." It doesn't tell you to add anything else, so you shouldn't add anything else, and what you added isn't valid either. But that's okay! Just be sure to only do as it says:

$.get("footer.html");

Thanks Marcus.

Haha, ya. Will do.

No problem! By the way, if you're ever in doubt, always go to the jQuery API site! It's there to help you out :P http://api.jquery.com

Definitely, will do.

Do you know of any resources where individuals will check on and/or improve my html-css? Building a basic 4 page website. I need to have that pristine before I can move onto jQuery AJAX forms in it.

Thanks for all your help. You have a great day!