PDA

View Full Version : Easy Slider Jquery problem



razvypp
01-23-2012, 01:02 AM
I have a problem , i am using easy Slider 1.7 and i have a problem on Pause Hover the element . THe pause hover works , but not as i want it to . As you can see in this example at the top of the page programator php (http://www.graphicvision.ro/projects/forex/index.php) , the slider pause on mouse hover , for example hover the image or the text , but if i move it from the element (say text) to the image element. it plays the next slide even i am in the slider . i want it when hover any element in the slider to stay paused .

jscheuer1
01-23-2012, 05:46 AM
That's a common problem with mouseover/out actions. They often fire too frequently to be of any use in predicting where the mouse actually is. jQuery has mouseenter/leave that often overcome this problem. So the first thing I'd try is, near the end of the easySlider script file where it has:


if(options.hoverpause && options.auto){
$(this).mouseover(function(){
clearTimeout(timeout);
}).mouseout(function(){
animate("next",false);
})
}

Change that to:


if(options.hoverpause && options.auto){
$(this).mouseenter(function(){
clearTimeout(timeout);
}).mouseleave(function(){
animate("next",false);
})
}

The browser cache may need to be cleared and/or the page refreshed to see changes.

If that doesn't fix it, leave it in place so I can check it out.

razvypp
01-23-2012, 12:24 PM
It works like a charm , thank you very much .