This example shows an AJAX request to a local file. Take a look at index.html
, which will retrieve the data and display it.
See: Live demo
Browsers don't allow you to do requests to file://
URLs (for security reasons), so you need to create a local server to run this one.
cd <this directory>
python -m SimpleHTTPServer
open http://localhost:8000