jsf 中每个 SelectOneMenu 项的工具提示
我的要求是为每个选项提供一个工具提示
SelectOneMenu
因为选项标签太大 不可能提供这么大尺寸的 SelectOneMenu 。所以 标签正在切割。这就是为什么我需要工具提示来显示 鼠标悬停在 SelectOneMenu 中的选项上时的整个值。
任何想法将不胜感激。
My requirement is to provide a tooltip
for every option in theSelectOneMenu
because label of option is so large
that it's not possible to provide such a large size SelectOneMenu .So the
label is cutting. Thats why i need tooltip to show
the whole value on mouse over of the options in the SelectOneMenu .
Any ideas will be appreciated.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
如果您使用“javax.faces.model.SelectItem”列表,您可以传递描述属性来显示每个选项的工具提示。
If you are using a list of "javax.faces.model.SelectItem" you can pass the description attribute to show a tooltip for each and every option.
您可以使用
javascript
。假设您的
selectOneMenu
如下。将此脚本添加到页面顶部。
You can use
javascript
.Assume your
selectOneMenu
as below.Add this script at the top of your page.