This forum is now read-only. Please use our new forums at discuss.codecademy.com.

How to use APIs with JavaScript Forum

View Course

168 points
37470a6b507558374b700a69e72a17a3?s=140&d=retro
Submitted by
bruce401
over 1 year ago

The pre-entered code isn't working

On all of these exercises here, it can't operate the code that's written as prompt. I send this:
var xhr = new XMLHttpRequest();
xhr.open("GET", "http://www.codecademy.com/doesnt_exist", false);
xhr.send();
// Add your code below!
console.log(xhr.status);

and get this:
NetworkError: Failed to execute 'send' on 'XMLHttpRequest': Failed to load 'http://www.codecademy.com/doesnt_exist'.


0 votes

permalink

 https://www.codecademy.com

https

661 points
0e06a1529331f8a71257039aae4f9ffc?s=140&d=retro
Submitted by
gtbsg2k1
over 1 year ago