added support for x-domain authentication - refactured authentication request ajax calls - added support for token authentication