简体   繁体   English

使用Qtip时如何禁用原始img标题

[英]How to disable original img title when using qtip

I am using jquery 1.4.2 and qtip-1.0.js 我正在使用jquery 1.4.2和qtip-1.0.js

in ie/7/6/8 whenever I hover over the image on which the tooltip is applied, I get the tooltip... but I also do get the original title... does not happen on the firefox though... Is there any option or setting specific to disable the img titl and just show the tooltip? 在ie / 7/6/8中,每当我将鼠标悬停在应用了工具提示的图像上时,我都会得到工具提示...但是我也得到了原始标题...虽然在Firefox上不会发生...是有没有禁用img titl的特定选项或设置,仅显示工具提示?

my code looks like this 我的代码看起来像这样

$('.selector img[title]').qtip({style: {name: 'green'},
                tip: true
},
              show: { delay: 100 },
              hide: { delay: 100 }
            });

Thanks 谢谢

在图像上,IE将创建一个带有“ alt”值而不是“ title”值的工具提示,因此您也需要删除“ alt”属性。

您可以在调用.qtip之后简单地调用.removeAttr('title')

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM