Jquery Qtip多ajax加载表单失败javascript控件

时间:2012-06-12 21:58:16

标签: javascript jquery ajax forms qtip2

你好我想打个电话:

$(function() {
$('a[href*=editar_domicilio]').each(function(){
    $(this).qtip({
        //id: 'modal', // Since we're only creating one modal, give it an ID so we can style it
        content: {
            // Set the text to an image HTML string with the correct src URL to the loading image you want to use
            text: 'Cargando...',
            ajax: {
                url: './abm_info_contacto_modificar.php?iddomicilio=' + $(this).attr('rel') + '&idpersona=' + $('#idpersona').val(),
                once: false // Re-fetch the content each time I'm shown
            },
            title: {
                text: 'Modificar Domicilio',
                button: true
            }
        },
        position: {
            my: 'center', // ...at the center of the viewport
            at: 'center',
            target: $(window)
        },
        show: {
            event: 'click', // Show it on click...
            solo: true, // ...and hide all other tooltips...
            modal: true // ...and make it modal
        },
        hide: function() { $('#formulario_domicilio').remove(); },
        style: 'ui-tooltip-light ui-tooltip-rounded'
    })
}).click(function(event) { event.preventDefault(); });// Make sure it doesn't follow the link when we click it

来自这样的表

<table align='center'><thead><tr><th></th><th id='DOMICILIO'>DOMICILIO</th><th id='FECHA'>FECHA</th><th id='LOCALIDAD'>LOCALIDAD</th><th id='TIPO'>TIPO</th><th id='ACTUAL'>ACTUAL</th></tr></thead><tbody><tr id='tr10'><td><a href="editar_domicilio?var=10" title="Modificar" rel="10"><img src='../../tema_blanco/modificar.png' border='0' style='margin:0px 1px 0px 1px;'></a>&nbsp;</td><td>&nbsp;5 N° 1 PISO 23 DEPTO 23&nbsp;</td><td>&nbsp;12/06/2012&nbsp;</td><td>&nbsp;MISIONES - COL. ALBERDI&nbsp;</td><td>&nbsp;COMERCIAL&nbsp;</td><td>&nbsp;NO&nbsp;</td></tr><tr id='tr3'><td><a href="editar_domicilio?var=3" title="Modificar" rel="3"><img src='../../tema_blanco/modificar.png' border='0' style='margin:0px 1px 0px 1px;'></a>&nbsp;</td><td>&nbsp;666 N° 67 PISO 68 DEPTO 69&nbsp;</td><td>&nbsp;11/06/2012&nbsp;</td><td>&nbsp;CATAMARCA - LAS JUNTAS&nbsp;</td><td>&nbsp;PARTICULAR&nbsp;</td><td>&nbsp;NO&nbsp;</td></tr><tr id='tr4'><td><a href="editar_domicilio?var=4" title="Modificar" rel="4"><img src='../../tema_blanco/modificar.png' border='0' style='margin:0px 1px 0px 1px;'></a>&nbsp;</td><td>&nbsp;5 N° 5&nbsp;</td><td>&nbsp;11/06/2012&nbsp;</td><td>&nbsp;MISIONES - COL. ALBERDI&nbsp;</td><td>&nbsp;PARTICULAR&nbsp;</td><td>&nbsp;NO&nbsp;</td></tr><tr id='tr5'><td><a href="editar_domicilio?var=5" title="Modificar" rel="5"><img src='../../tema_blanco/modificar.png' border='0' style='margin:0px 1px 0px 1px;'></a>&nbsp;</td><td>&nbsp;5 N° 11 PISO 22 DEPTO 22&nbsp;</td><td>&nbsp;11/06/2012&nbsp;</td><td>&nbsp;BUENOS AIRES - J. B. ALBERDI&nbsp;</td><td>&nbsp;PARTICULAR&nbsp;</td><td>&nbsp;NO&nbsp;</td></tr></table>

问题出现在名为width ajax的表单中,我调用一次并且工作正常但是如果我关闭它并尝试从表上的另一个链接打开控制输入的javascript(包含在表单宽度ajax中)失败, “我想”这个流行的形式仍然存在于dom中,我希望你能理解,因为我的英语很糟糕!非常感谢你。

0 个答案:

没有答案