refactor $.ajax() to use success/fail.  Move logging to global ajax events