[英]flexsider not loading on production
I am trying to make a slider using flexsider but it is not loading on production. 我正在尝试使用flexsider制作滑块,但它并未在生产中加载。 It is working well on development. 它在发展方面运作良好。 I am getting this error: 我收到此错误:
Uncaught TypeError: $(...).flexslider is not a function 未捕获的TypeError:$(...)。flexslider不是函数
Here is the link to website: https://mybagicha.herokuapp.com/ 这是网站链接: https : //mybagicha.herokuapp.com/
jQuery(window).load(function(){
$('.flexslider').flexslider({
animation: "fade",
slideshowSpeed: 4000,
animationSpeed: 600,
controlNav: false,
directionNav: true,
controlsContainer: ".flex-container" // the container that holds the flexslider
});
});
That means jQuery
is not defined. 这意味着未定义jQuery
。 If you load jQuery
twice that's also happened the error, try figure out that. 如果您两次加载jQuery
,同样也发生了该错误,请尝试找出原因。
And try to the following added $
to the 并尝试将以下添加到$
jQuery(window).load(function($) {
$('.flexslider').flexslider({
//Code here
});
});
Hope to help 希望对大家有帮助
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.