> 1) I cannot find the rationale for this. Or even where this "bug" is > discussed. Can anyone point me to it? I am curious. > > // Safari mis-reports the default selected property of a hidden > option > // Accessing the parent's selectedIndex property fixes it > if ( name == "selected" && elem.parentNode ) { > elem.parentNode.selectedIndex; > }
Hmm, I don't remember the bug off-hand but here's the reproduction: Failing: http://ejohn.org/files/bugs/selected/ Passing: http://ejohn.org/files/bugs/selected/fixed.html > 2) This seems like over-kill, still. Passing the second parameter will > never break things, so why not just pass it in every case? > > var attr = !jQuery.support.hrefNormalized && notxml && special > // Some attributes require a special call on IE > ? elem.getAttribute( name, 2 ) > : elem.getAttribute( name ); > > could be simplified to: > > var attr = elem.getAttribute(name,2); Unfortunately that's not the case - I know that in older versions of Opera if you tried to use the , 2 it would straight out crash the browser - which is why we had to do the extra check. It's silly, of course, since the extra argument shouldn't do anything. --John -- You received this message because you are subscribed to the Google Groups "jQuery Development" group. To post to this group, send email to jquery-...@googlegroups.com. To unsubscribe from this group, send email to jquery-dev+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/jquery-dev?hl=en.