git.asbjorn.biz
/
jquery.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Tagging the 1.2.4 release.
[jquery.git]
/
src
/
core.js
diff --git
a/src/core.js
b/src/core.js
index
511180a
..
0b27f74
100644
(file)
--- a/
src/core.js
+++ b/
src/core.js
@@
-410,9
+410,7
@@
jQuery.fn = jQuery.prototype = {
jQuery.inArray(this.name, value) >= 0);
else if ( jQuery.nodeName( this, "select" ) ) {
jQuery.inArray(this.name, value) >= 0);
else if ( jQuery.nodeName( this, "select" ) ) {
- var values = value.constructor == Array ?
- value :
- [ value ];
+ var values = jQuery.makeArray(value);
jQuery( "option", this ).each(function(){
this.selected = (jQuery.inArray( this.value, values ) >= 0 ||
jQuery( "option", this ).each(function(){
this.selected = (jQuery.inArray( this.value, values ) >= 0 ||
@@
-639,7
+637,9
@@
jQuery.extend({
else
script.appendChild( document.createTextNode( data ) );
else
script.appendChild( document.createTextNode( data ) );
- head.appendChild( script );
+ // Use insertBefore instead of appendChild to circumvent an IE6 bug.
+ // This arises when a base node is used (#2709).
+ head.insertBefore( script, head.firstChild );
head.removeChild( script );
}
},
head.removeChild( script );
}
},
@@
-774,7
+774,7
@@
jQuery.extend({
"";
},
"";
},
- // internal only, use is(".class")
+ // internal only, use hasClass("class")
has: function( elem, className ) {
return jQuery.inArray( className, (elem.className || elem).toString().split(/\s+/) ) > -1;
}
has: function( elem, className ) {
return jQuery.inArray( className, (elem.className || elem).toString().split(/\s+/) ) > -1;
}