Note that this code doesn't work because the AJAX code is accessing a script on a different server. The following will work because the server contains both the HTML page and the script. Note how the URL is written for the AJAX access on the icarus example