Monday, May 03, 2010

JQuery Supersubs IE7/8 Tweak

I probably just botched my version of superfish.css, but I found that for supersubs to work properly in Internet Explorer 7 and 8, I had to change:
                var emWidth = $ul.add($LIs).add($As).css({
                    'float' : 'none',
                    'width'    : 'auto'
                })
To
                var emWidth = $ul.add($LIs).add($As).css({
                    'float' : 'none',
                    'overflow' : 'visible',
                    'width'    : 'auto'
                })
I also added an extraOffset setting which nudges submenus left or right depending on the alignment, but it's probably another fix my own bad css.  I did it to avoid z-index problems which are made worse by bgIframe in IE6.  I'm not going to share this extraOffset code both because it's trivial and probably not generally applicable if you don't screw up superfish.css (which is too complicated for me).

I tested both changes successfully in IE6,IE7,IE8, and firefox. 

No comments: