如何使用 Jquery TipTip 插件制作粘性工具提示
我正在使用 Jquery TipTip 插件。如果您知道更好的插件,易于使用,可以告诉我。好吧,现在我可以让它工作了。它显示工具提示非常好。但我想制作粘性工具提示。我的意思是,当您将鼠标悬停在对象上时,将显示工具提示,直到人们单击我放在工具提示内的链接,因此当人们单击时,工具提示将关闭。他们的文档为零,所以我无法解决它。
Tiptip主页: http://code.drewwilson.com/entry/tiptip-jquery-plugin
这里他们怎么说退出并输入
Enter:回调函数 - 每次将鼠标悬停在应用了 TipTip 的元素上时运行的自定义函数。
exit:回调函数 - 每次将鼠标移出应用了 TipTip 的元素时运行的自定义函数。
我如何从 body 内的 Tiptip 源代码调用函数。
I am using Jquery TipTip plugin. If you know better plugin that way easy to use you can tell me. Okay now i am able to make it work. It displays tooltips very good. But i want to make sticky tooltips. I mean when you hover mouse over the object tooltip will be displayed and until person clicks the link i put inside tooltip ,so when person clicked the tooltip will be closed. Their documentation is zero so i couldn't solve it.
tiptip main page : http://code.drewwilson.com/entry/tiptip-jquery-plugin
Here how they say exit and enter
enter: callback function - Custom function that is run each time you mouseover an element with TipTip applied to it.
exit: callback function - Custom function that is run each time you mouseout of an element with TipTip applied to it.
How can i call function from tiptip source code inside body.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您是否检查了插件的 keepAlive 选项?这将使工具提示保持在屏幕上,直到用户将鼠标移出工具提示(而不是离开目标对象本身)。
似乎没有办法以编程方式执行此操作。您必须扩展插件本身或删除 mouseout 事件处理程序。
实际上,在重新阅读文档后,您可以尝试使用退出回调来防止工具提示消失,如下所示:
但我不确定这是否有效。查看源代码,您可以修改 deactivate_tiptip() 函数。第三行是隐藏工具提示的行。
Did you check the keepAlive option for the plugin? This keeps the tooltip on the screen until the user mouses out of the tooltip (rather than off the targeted object itself).
There doesn't seem to be a way to do this programatically. You would have to extend the plugin itself or remove the mouseout eventhandler.
Actually after rereading the documentation, you could try to prevent the tooltip from disappearing using the exit callback like so:
But I'm not sure if this would work. Looking at the source, you could modify the deactivate_tiptip() function. The third line is the one that hides the tooltip.
解决办法有很多种。
另请检查尝试 QTip
http://slodive.com/web-development/best-jquery-tooltip-plugins/
http://www.1stwebdesigner.com/css/stylish-jquery-tooltip-plugins-webdesign/
检查这些 http://craigsworks.com/projects/qtip/docs/reference/ 选项请参阅按钮 true 或 false 。
There are many solution .
Also check Try QTip
http://slodive.com/web-development/best-jquery-tooltip-plugins/
http://www.1stwebdesigner.com/css/stylish-jquery-tooltip-plugins-webdesign/
Check these http://craigsworks.com/projects/qtip/docs/reference/ options see button true or false .