【发布时间】:2011-01-15 08:36:09
【问题描述】:
我已经编写了这段代码来将“jQuery Tooltip 插件”应用于 ajax 加载的元素。
我的意思是我想在鼠标悬停时显示工具提示的行是由 ajax 加载到页面中的。 这是代码:
$("[id^=pane]").delegate("[id^=comm]","mouseover",function() {
$(this).tooltip({
// each trashcan image works as a trigger
tip: "#tooltip",
// custom positioning
position: "center right",
// move tooltip a little bit to the right
offset: [0, 15],
// there is no delay when the mouse is moved away from the trigger
delay: 0
}).dynamic({ bottom: { direction: "down", bounce: true } });
});
鼠标悬停时显示工具提示但firebug报告此错误:
"$(this).tooltip({tip: "#tooltip", position: "center right", offset: [0, 15], delay: 0}).dynamic 不是函数"
是因为使用了$(this)吗???
【问题讨论】:
标签: jquery-plugins jquery tooltip