git.asbjorn.biz
/
jquery.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Add a feature test for options inside a disabled select. Follow-up to 157a383dae5335e...
[jquery.git]
/
src
/
attributes.js
diff --git
a/src/attributes.js
b/src/attributes.js
index
1afcf2a
..
dd6a3e7
100644
(file)
--- a/
src/attributes.js
+++ b/
src/attributes.js
@@
-164,8
+164,9
@@
jQuery.fn.extend({
var option = options[ i ];
// Don't return options that are disabled or in a disabled optgroup
var option = options[ i ];
// Don't return options that are disabled or in a disabled optgroup
- if ( option.selected && option.getAttribute("disabled") === null &&
+ if ( option.selected && (jQuery.support.optDisabled ? !option.disabled : option.getAttribute("disabled") === null ) &&
(!option.parentNode.disabled || !jQuery.nodeName( option.parentNode, "optgroup" )) ) {
(!option.parentNode.disabled || !jQuery.nodeName( option.parentNode, "optgroup" )) ) {
+
// Get the specific value for the option
value = jQuery(option).val();
// Get the specific value for the option
value = jQuery(option).val();