Trying to convert JQuery to Mootools - show hide using mouseenter and mouseleave
I am trying to port the code below to mootools 1.1 code but a开发者_如何学运维m having no luck
jQuery(document).ready(
function(){
jQuery("div#fpss-nav_activator").bind("mouseenter",function(){
jQuery("div#navi-outer").stop(true, true).show("slow");
}).bind("mouseleave",function(){
jQuery("div#navi-outer").stop(true, true).hide("slow");
});
});
Here you go:
window.addReady('domready', function() {
var navi = $("navi-outer");
$("fpss-nav_activator").addEvent('mouseenter', function() {
navi.slide('in');
}).addEvent('mouseleave', function() {
navi.slide('out');
});
});
精彩评论