Get Even More Visitors To Your Blog, Upgrade To A Business Listing >>

jQuery SelectBox Plugin not working in IE7, 8, or 9

jQuery SelectBox Plugin not working in IE7, 8, or 9

Problem

I have this Jquery Selectbox Plugin that I have styled to fit what I need and also a "Go" button to go to the href given in the value of each option. The functionality and style work beautifully in FF, Chrome, and IE10. However does not work at all in IE7, 8 , and 9.

I have tried a wide range of things that I've come across in here including making sure there was a z-index on all of my divs using the following jQuery fix:

    $(function () {
        var zIndexNumber = 1000;
        $('div').each(function () {
        $(this).css('zIndex', zIndexNumber);
        zIndexNumber -= 10;
        });
    });

Nothing I have tried has made any difference in IE. I'm almost certain my problem exists in my css. I use a lot of css3 styles and have tried removing them...I have yet to come up with a solution. Any help at all with this would be greatly appreciated! :)

HERE IS MY JSFIDDLE: http://jsfiddle.net/defmod33/hX2Ma/

And by "Not Working" I mean the drop down portion is not showing up at all...

Problem courtesy of: Lars

Solution

I finally solved this issue. The problem was in the CSS like I expected. The selectbox dropdown functionality would break do to the "filter:" style tag that provides a gradient for IE. I could have just removed the style tag, but I decided to create a couple conditional comments just in case I found a better fix for this situation in the future (I wanted to keep the "filter:" just in case it was needed later on).

Conditional Comments Used:

    

    

The first one gets rid of the filter for IE9 and below. The second one gives a second background color for the browsers that will not have one after getting rid of the filter (IE8 and below)

Solution courtesy of: Lars

Discussion

View additional discussion.



This post first appeared on CSS3 Recipes - The Solution To All Your Style Problems, please read the originial post: here

Share the post

jQuery SelectBox Plugin not working in IE7, 8, or 9

×

Subscribe to Css3 Recipes - The Solution To All Your Style Problems

Get updates delivered right to your inbox!

Thank you for your subscription

×