简体   繁体   中英

Jquery Cycle plugin with maphilight stops working

I am using jquery cycle plugin with jquery maphilight to highlight products on the flyer that is causing some problem as you can see in first screenshot how it works but when i add maphilight then check screenshot 2 this is how it shows. you can check it on jsFiddle here http://jsfiddle.net/Yjuqs/

This is the code for jquery cycle plugin and jquery maphilight

<script type="text/javascript" src="js/jquery.cycle.all.js" ></script>
<script src="js/jquery.cycle2.js"></script>
<script src="js/jquery.cycle2.carousel.js"></script>
<script>$.fn.cycle.defaults.autoSelector = '.slideshow';</script>
$(function() {
        $('img').maphilight({
            fade:true,
            fadeDuration:500 ,
            fillOpacity :0.2,
            stroke:false,
            fillColor:'ffffff'

        });
    });

截图 1截图 2

Please use document ready jQuery function, call function when the document ready

<script>
$(document).ready(function(){
  $.fn.cycle.defaults.autoSelector = '.slideshow'; //call slider
})
</script>

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM