Create ajax.js

Creates an object for AJAX interactions with the server.