这是我的代码
<a href="http://linkurl" class="link" title="sometitle">
text link
<span class="hidden-tooltip-data" style="display: none;"> <a
href="http://www.google.ca"> my link here destroy everything </a
</span>
</a>
我这里用的是Poshy脚本
$('.link').each(function() {
var tooltip = $(".hidden-tooltip-data",this).html();
$(this).attr("title","");
$(this).poshytip({
content: function(updateCallback) {
return tooltip;
}
});
});
最佳答案
嵌套链接是非法的。 the HTML 4.01 Specification 中明确提到了这种情况.
关于jquery - 如何在 <a> 中的 <span> 中放置一个 <a> 链接?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/6179425/