我正在使用 jQuery qTip 插件,并且无法从另一个元素将 html 内容加载到其中。
我有以下代码:
$('.tip').qtip({
content: {
text: $(this).next('.product_info').html()
}
});
使用以下html:
<a href="#" class="tip">An Image</a>
<div class="product_info">Some content</div>
问题是我似乎无法使用“$(this)”,那么如何引用当前的“.tip”?
谢谢!