JQUERY UI Dialog Box - Close Function

Posted by David Bonnici on Stack Overflow See other posts from Stack Overflow or by David Bonnici
Published on 2008-12-14T19:09:21Z Indexed on 2010/04/12 21:42 UTC
Read the original article Hit count: 372

Filed under:
|
|

Hi Guys,

I have a problem with the jquery-ui dialog box. The problem is that when I close the dialog box and then I click on the link that triggers it, it does not pop-up again unless I refresh the page. How can I call the dialog box back without refreshing the actual page. Have a look:

$(document).ready(function() {


    $('#showTerms').click(function()
    {
        $('#terms').css('display','inline');


        $('#terms').dialog({resizable: false,
        modal: true,
        width: 400,
        height: 450,
        overlay: { backgroundColor: "#000", opacity: 0.5 },
        buttons:{ "Close": function() { $(this).dialog("close"); } },
        close: function(ev, ui) { $(this).remove(); },

    }); 

});

Thanks

© Stack Overflow or respective owner

Related posts about jQuery

Related posts about jquery-ui