git.asbjorn.biz
/
jquery.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Replace build system with a faster new one that uses Node and UglifyJS and generates...
[jquery.git]
/
src
/
ajax.js
diff --git
a/src/ajax.js
b/src/ajax.js
index
5c4d469
..
871481d
100644
(file)
--- a/
src/ajax.js
+++ b/
src/ajax.js
@@
-175,11
+175,12
@@
jQuery.extend({
timeout: 0,
data: null,
dataType: null,
timeout: 0,
data: null,
dataType: null,
- dataTypes: null,
username: null,
password: null,
cache: null,
traditional: false,
username: null,
password: null,
cache: null,
traditional: false,
+ headers: {},
+ crossDomain: null,
*/
xhr: function() {
return new window.XMLHttpRequest();
*/
xhr: function() {
return new window.XMLHttpRequest();
@@
-583,12
+584,6
@@
jQuery.extend({
// Remove hash character (#7531: and string promotion)
s.url = ( "" + s.url ).replace( rhash , "" );
// Remove hash character (#7531: and string promotion)
s.url = ( "" + s.url ).replace( rhash , "" );
- // Uppercase the type
- s.type = s.type.toUpperCase();
-
- // Determine if request has content
- s.hasContent = ! rnoContent.test( s.type );
-
// Extract dataTypes list
s.dataTypes = jQuery.trim( s.dataType || "*" ).toLowerCase().split( /\s+/ );
// Extract dataTypes list
s.dataTypes = jQuery.trim( s.dataType || "*" ).toLowerCase().split( /\s+/ );
@@
-604,13
+599,19
@@
jQuery.extend({
}
// Convert data if not already a string
}
// Convert data if not already a string
- if ( s.data && s.processData && typeof s.data != "string" ) {
+ if ( s.data && s.processData && typeof s.data !== "string" ) {
s.data = jQuery.param( s.data , s.traditional );
}
// Apply prefilters
jQuery.ajaxPrefilter( s , options );
s.data = jQuery.param( s.data , s.traditional );
}
// Apply prefilters
jQuery.ajaxPrefilter( s , options );
+ // Uppercase the type
+ s.type = s.type.toUpperCase();
+
+ // Determine if request has content
+ s.hasContent = ! rnoContent.test( s.type );
+
// Watch for a new set of requests
if ( s.global && jQuery.active++ === 0 ) {
jQuery.event.trigger( "ajaxStart" );
// Watch for a new set of requests
if ( s.global && jQuery.active++ === 0 ) {
jQuery.event.trigger( "ajaxStart" );