开发者

jQuery Dropdown Menu Under IE7

I have been fighting a stupid IE6/7 problem for awhile now, and hope someone with more experience than I can save me more wasted days.

I implemented a jQuery/CSS drop down menu that works fantastically under practically all browsers... except for our beloved IE7. The following link points to a stripped-down test site that breaks down the problem into the minimal number of components. You will find some main menu items tha开发者_开发技巧t drop down into additional sub-items when hovered, but they don't drop down in IE7. Please take a look at the following page, and help me understand where I have gone wrong... and what I can do to fix this in IE7.

Thanks in advance!

http://eatyourpet.info/menutest/index.php


Without going through your code (there's a lot of CSS styles, and it's probably going to be something really small) what you're trying to implement is a suckerfish dropdown ( http://www.alistapart.com/articles/dropdowns/ ).

If you want to style it nicely like you've, it becomes a little more complicated, but this fiddle – http://jsfiddle.net/SZDkw/ – is a super basic implementation that works in IE 7, so take something that works and then build on that while checking in IE 7 as you go along.


Try this code. I don't have IE7 to test. Let me know if it was helpful:

$('#cssdropdown li.headlink').hover(function() { $(this).find('ul').toggle(); });
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜