I am trying to get these 2 select drop downs to work which basically rely on each other for out of stock. The idea is that out of stock combination would be disabled from the user selection. This works fine in all browsers except IE.
I found a script for IE which basically adds disabled class and does an alert pop up and then resets the select dropdown.
Here is a demo: http://jsbin.com/osipe5/2
In that, please select size as 1X. As you can see everything works perfectly. We are good. Now select size 2X. In the color dropdown "White" has the disabled class. That is not correct. The issue is somewhere开发者_如何学JAVA with ieLessThan8OptionDisable()
Any help is much appreciated.
Thanks
I'm guessing the problem is this line in ieLessThan8OptionDisable()
:
this.blur();
Change it to $(this).blur();
. But seriously, please stop writing browser-specific code with jQuery.
Since you're running into a common IE pre-8 bug, you might want to see this question.
精彩评论