Is there is any possible way to add tool tip on mouse hover of a tag having long text.
例如: -
我有一个名称为EveryThingIsPossibleRightHere
的标签,目前标签显示为
EveryTh....
,我想知道如何在鼠标悬停时显示完整的标签名称,就像选择的Jquery工具提示一样?
我已经为所选的jQuery插件的每个选项完成了工具提示,但是没有运气。
通过使用标题属性可以设置工具提示,如下所示。
<option value="1" title='EveryThingIsPossibleRightHere'>EveryThingIsPossibleRightHere</option>
选择的方法
Go to line no 869 of chosen.jquery.js
After "class": "search-choice", Add "title": item.text
In order to show the tool tip
最终代码将
choice = $('<li />', {
"class": "search-choice",
"title": item.text
}).html("<span>" + item.html + "</span>");
<<p> 为视图/strong> 只需将鼠标悬停在标签上,就可以看到工具提示