Here you will find: http://james.padolsey.com/jquery/#v=1.6.2&fn=jQuery.ajax
This site is very useful for going through jQuery source code.
The source in the case of the above link does not work:
function (url, options) { // If url is an object, simulate pre-1.5 signature if (typeof url === "object") { options = url; url = undefined; } // Force options to be an object options = options || {}; var // Create the final options object s = jQuery.ajaxSetup({}, options), // Callbacks context callbackContext = s.context || s, // Context for global events // It the callbackContext if one was provided in the options // and if it a DOM node or a jQuery collection globalEventContext = callbackContext !== s && (callbackContext.nodeType || callbackContext instanceof jQuery) ? jQuery(callbackContext) : jQuery.event, // Deferreds deferred = jQuery.Deferred(), completeDeferred = jQuery._Deferred(), // Status-dependent callbacks statusCode = s.statusCode || {}, // ifModified key ifModifiedKey, // Headers (they are sent all at once) requestHeaders = {}, requestHeadersNames = {}, // Response headers responseHeadersString, responseHeaders, // transport transport, // timeout handle timeoutTimer, // Cross-domain detection vars parts, // The jqXHR state state = 0, // To know if global events are to be dispatched fireGlobals, // Loop variable i, // Fake xhr jqXHR = { readyState: 0, // Caches the header setRequestHeader: function (name, value) { if (!state) { var lname = name.toLowerCase(); name = requestHeadersNames[lname] = requestHeadersNames[lname] || name; requestHeaders[name] = value; } return this; }, // Raw string getAllResponseHeaders: function () { return state === 2 ? responseHeadersString : null; }, // Builds headers hashtable if needed getResponseHeader: function (key) { var match; if (state === 2) { if (!responseHeaders) { responseHeaders = {}; while ((match = rheaders.exec(responseHeadersString))) { responseHeaders[match[1].toLowerCase()] = match[2]; } } match = responseHeaders[key.toLowerCase()]; } return match === undefined ? null : match; }, // Overrides response content-type header overrideMimeType: function (type) { if (!state) { s.mimeType = type; } return this; }, // Cancel the request abort: function (statusText) { statusText = statusText || "abort"; if (transport) { transport.abort(statusText); } done(0, statusText); return this; } }; // Callback for when everything is done // It is defined here because jslint complains if it is declared // at the end of the function (which would be more logical and readable) function done(status, statusText, responses, headers) { // Called once if (state === 2) { return; } // State is "done" now state = 2; // Clear timeout if it exists if (timeoutTimer) { clearTimeout(timeoutTimer); } // Dereference transport for early garbage collection // (no matter how long the jqXHR object will be used) transport = undefined; // Cache response headers responseHeadersString = headers || ""; // Set readyState jqXHR.readyState = status ? 4 : 0; var isSuccess, success, error, response = responses ? ajaxHandleResponses(s, jqXHR, responses) : undefined, lastModified, etag; // If successful, handle type chaining if (status >= 200 && status < 300 || status === 304) { // Set the If-Modified-Since and/or If-None-Match header, if in ifModified mode. if (s.ifModified) { if ((lastModified = jqXHR.getResponseHeader("Last-Modified"))) { jQuery.lastModified[ifModifiedKey] = lastModified; } if ((etag = jqXHR.getResponseHeader("Etag"))) { jQuery.etag[ifModifiedKey] = etag; } } // If not modified if (status === 304) { statusText = "notmodified"; isSuccess = true; // If we have data } else { try { success = ajaxConvert(s, response); statusText = "success"; isSuccess = true; } catch(e) { // We have a parsererror statusText = "parsererror"; error = e; } } } else { // We extract error from statusText // then normalize statusText and status for non-aborts error = statusText; if (!statusText || status) { statusText = "error"; if (status < 0) { status = 0; } } } // Set data for the fake xhr object jqXHR.status = status; jqXHR.statusText = statusText; // Success/Error if (isSuccess) { deferred.resolveWith(callbackContext, [success, statusText, jqXHR]); } else { deferred.rejectWith(callbackContext, [jqXHR, statusText, error]); } // Status-dependent callbacks jqXHR.statusCode(statusCode); statusCode = undefined; if (fireGlobals) { globalEventContext.trigger("ajax" + (isSuccess ? "Success" : "Error"), [jqXHR, s, isSuccess ? success : error]); } // Complete completeDeferred.resolveWith(callbackContext, [jqXHR, statusText]); if (fireGlobals) { globalEventContext.trigger("ajaxComplete", [jqXHR, s]); // Handle the global AJAX counter if (! (--jQuery.active)) { jQuery.event.trigger("ajaxStop"); } } } // Attach deferreds deferred.promise(jqXHR); jqXHR.success = jqXHR.done; jqXHR.error = jqXHR.fail; jqXHR.complete = completeDeferred.done; // Status-dependent callbacks jqXHR.statusCode = function (map) { if (map) { var tmp; if (state < 2) { for (tmp in map) { statusCode[tmp] = [statusCode[tmp], map[tmp]]; } } else { tmp = map[jqXHR.status]; jqXHR.then(tmp, tmp); } } return this; }; // Remove hash character (