是否可以顯示來自屬性data-x的qtip2 html內容?屬性data-x的jQuery html內容?
$('.icon').qtip({ content: $('.icon').attr('x') });
如果你正在做一個自定義屬性的使用:
jQuery的這段代碼不能在屬性數據-X
$('.icon[data-x]').qtip({
content: {
attr: 'data-x'
},
position: {
my: 'bottom center',
at: 'top center'
}
});
HTML
<span class="icon" href="#" data-x="<strong>HTML</strong><br>content"></span>
你應該有什麼工作,假設瀏覽器不會因爲無效而破壞你的跨度。 – 2013-05-02 16:12:08