I need a second instance of jQuery, or at least of its AJAX facility. The problem is that I need to contact two servers, and they use different authentication methods.
So in one case I need to set a header:
$.ajaxSetup({
headers: {
'Authorization': auth_string
}
});
And not in the other case. If I send headers, the request will fail.
As I need to get data from both servers all the time, I don't want to manipulate the headers before each AJAX call. So it would be nice to use two different AJAX/jQuery objects.
How can I achieve this?