cleaner ajax.js with general purpose ajax calls