jQuery工具提示将内容添加到页面底部 [英] jQuery tooltip append content in bottom of the page

查看:162
本文介绍了jQuery工具提示将内容添加到页面底部的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用jQuery工具提示.工具提示会出现在正确的位置;它会在正确的时间出现和消失.一切似乎都能正常工作..但是 当出现提示时,内容也将显示在页面底部,并且不再消失.这是我的代码:

I am using a jQuery tooltip. The tooltip appears in the correct place; It appears and disappears in the correct moment. Everything seems to work correctly.. BUT When the toltip appear, the content appear ALSO in tne bottom of the page and it does not disappear anymore. Here my code:

$(document).ready(function () {
    $(document).tooltip({
        items: "#img_help_easypay",
        show: {
            effect: "slideDown",
            delay: 250
        },
        content: function () {
            return "<span>Title</span><br />" +
                   "<p>" +
                   "   <span>bla bla bla</span><br />" +
                   "   <span>bla bla bla.</span>" +
                   "</p>"
        }
    });
});

img_help_easypay在哪里

<img id="img_help_easypay" src="/Styles/img/info.png" alt="aiuto easypay" style="vertical-align:top" />

非js错误...有人可以帮助我吗?谢谢.

Non js error... Can anyone help me? Thank you..

在页面底部,div的角色为"log"

In bottom of page the div has role="log"

推荐答案

根据jQuery UI bug平台上的这张票证,这是jQuery UI 1.11.0中启动的一项功能,用于增加可访问性:

According to this ticket from the jQuery UI bugs platform, this is a feature started in jQuery UI 1.11.0 to increase accessibility : http://bugs.jqueryui.com/ticket/10689

如果要从代码中完全删除附加的<div>,则必须销毁工具提示:

If you want to entirely remove the appended <div> from your code, you have to destroy the tooltip :

$(document).tooltip( "destroy" );

这篇关于jQuery工具提示将内容添加到页面底部的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆