jQuery工具提示不起作用 [英] jQuery tooltip is not working
问题描述
我想要一个工具提示来显示我在特定链接上展开的时间。它不起作用。注释掉的警报正在运行,因此事件不是问题。这是我的javascript代码:
I want a tooltip to show when I rollover on particular links. It's not working. The commented out alert is working, so event is not the issue. This is my javascript code:
$(window).load( function() {
$("a").each(function() {
if(this.text==" View image") {
$(this).mouseover(function() {
// alert("blabla");
$(this).tooltip();
});
}
});
});
在我的身上包含的html文件是:
on my html file the includes are:
<script type="text/javascript" language="javascript" src="http://code.jquery.com/jquery-latest.js"></script>
<script type="text/javascript" language="javascript" src="jquery.tooltip.min.js"></script>
<script type="text/javascript" language="javascript" src="mainscript.js"></script>
我很感激一些帮助。
更新:删除鼠标悬停没有帮助
UPDATE: removing mouseover doesn't help
推荐答案
删除鼠标悬停功能。该插件不需要您添加自定义鼠标悬停功能。它是从你的插件完成的。
Remove the mouseover function. The plugin doesn't require you to add a custom mouseover function. It's done from the plugin for you.
if(this.text==" View image") {
$(this).tooltip();
}
希望这会有所帮助^^
Hope this helps ^^
将主jQuery函数更改为$(document).ready(function(){});
Change the main jQuery function to $(document).ready(function(){});
这可能现在可以正常工作〜
This will probably work now~
这篇关于jQuery工具提示不起作用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!