hoverIntent()不是一个函数 [英] hoverIntent() not a function

查看:109
本文介绍了hoverIntent()不是一个函数的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我似乎无法让hoverIntent插件工作。这绝对是加载jQuery和hoverIntent。但是,.hoverIntent()是不是函数。 (.hover()正常工作)。

I can't seem to get hoverIntent plugin to work. It's definitely loading jQuery and hoverIntent. But, .hoverIntent() is "not a function". (.hover() works fine).

<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.5/jquery.min.js"></script>

<script type="text/javascript" src="js/jquery.hoverIntent.minified.js"></script>

<script type="text/javascript">
$(document).ready(function() {
    $('#portfolio-circle').hoverIntent(
        function() {
            $('#portfolio-hover').fadeTo('normal', 1);
            $('#portfolio-caption').fadeTo('normal', 1);
        },
        function() {
            $('#portfolio-hover').fadeTo('normal', 0);
            $('#portfolio-caption').fadeTo('normal', 0);
        }
    );
});
</script>


推荐答案

检查您是否引用了两个不同版本的jquery错误。我遇到了jqueryui类似的错误,其中一切都加载正常,但后来我意识到有两个不同版本的jquery被引用。

Check whether you are referencing two different versions of jquery by mistake. I faced a similar error with jqueryui where everything was loading fine, but I realized later that there were two different versions of jquery being referenced.

这篇关于hoverIntent()不是一个函数的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆