开发者

JQuery / Javascript Submenu Hover Problem

I have a problem in a jquery dropdow开发者_运维百科n menu. In my example (link in the bottom) I want that when I hover the Submenu the color of the current menu item (item 2) stays in hover state (color white in example).

I want this in jquery/javascript and not css.

Link To Live Example with complete Code

Thanks


$("ul.submenu li a").css({'background-color': '#fdfa02'});
$("ul.submenu").css({'background-color': '#fdfa02'});
$("ul.submenu2").css({'background-color': '#fdfa02'});   
$('ul.submenu li a').css('color', '#00FF00');

//change the menu text color on mouse over
$('ul.menu li').hover(function () {    
     $(this).find("span:first a").css({color:'#FFFFFF'});    
},
function () {
    $(this).find("span:first a").css({color:'#000000'});  
});
0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜