Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Adds support for username and password to $.ajax

  • Loading branch information...
commit b91eef070db6ebe1ef7654e24c33d6eb9f0fca80 1 parent 9487538
@wycats wycats authored
Showing with 4 additions and 2 deletions.
  1. +4 −2 src/ajax.js
View
6 src/ajax.js
@@ -144,7 +144,9 @@ jQuery.extend({
contentType: "application/x-www-form-urlencoded",
processData: true,
async: true,
- data: null
+ data: null,
+ username: null,
+ password: null
},
// Last-Modified header cache for next request
@@ -258,7 +260,7 @@ jQuery.extend({
var xml = window.ActiveXObject ? new ActiveXObject("Microsoft.XMLHTTP") : new XMLHttpRequest();
// Open the socket
- xml.open(s.type, s.url, s.async);
+ xml.open(s.type, s.url, s.async, s.username, s.password);
// Need an extra try/catch for cross domain requests in Firefox 3
try {
Please sign in to comment.
Something went wrong with that request. Please try again.