X-Git-Url: http://git.asbjorn.biz/?a=blobdiff_plain;f=src%2Fjquery%2Fjquery.js;h=befaef64d03b903dcf1e8513525ca0fb365fcc8f;hb=46806957f478d4f1435f13768cc85c1a39996d33;hp=e58f895df21d94f54b2dc5cbfe92120c5f5dfde4;hpb=495ecb70b2b097e7d4a1ffe46d44562210cdc051;p=jquery.git diff --git a/src/jquery/jquery.js b/src/jquery/jquery.js index e58f895..befaef6 100644 --- a/src/jquery/jquery.js +++ b/src/jquery/jquery.js @@ -1470,7 +1470,7 @@ jQuery.extend({ if ( arg.length === 0 ) return; - if ( arg[0] == undefined ) + if ( arg[0] == undefined || jQuery.nodeName(arg[0],"form") ) r.push( arg ); else r = jQuery.merge( r, arg ); @@ -1513,7 +1513,6 @@ jQuery.extend({ if ( name == "opacity" && jQuery.browser.mozilla && value == 1 ) value = 0.9999; - // // Certain attributes only work when accessed via the old DOM 0 way if ( fix[name] ) { @@ -1525,10 +1524,11 @@ jQuery.extend({ // IE elem.getAttribute passes even for style else if ( elem.tagName ) { - if ( value != undefined ) - elem.setAttribute( name, value ); + if ( value != undefined ) elem.setAttribute( name, value ); + if ( name == "href" && jQuery.browser.msie && !jQuery.isXMLDoc(elem) ) return elem.getAttribute( name, 2 ); return elem.getAttribute( name ); + // elem is actually elem.style ... set the style } else { name = name.replace(/-([a-z])/ig,function(z,b){return b.toUpperCase();}); if ( value != undefined ) elem[name] = value;