Added ajax defaults that are used to override any default ajax setups to prevent our ajax communications from failing.

#2511
Added tests to verify the correctness of our ajax default overriding.

#2511