I have a problem where I try to make a self contained script that will
show a dialog using jQuery UI dialog. Problem is, if I create the div
programatically (inside the script) the dialog never shows. Here is
the sample code I've got so far:

function showDialog(){

    var theDiv = jQuery("<div id='DialogDiv' class='DialogDiv'>Hi
there</div>").appendTo("body");
    var dialogOptions = {
        autoOpen: false,
        buttons: { "Ok": function(){ alert("hi");} },
        height: 300,
        modal: true,
        title: "Properties"
    }

    var theDialog = theDiv.dialog(dialogOptions);
    theDialog.dialog('show');
}

I know that the div I create is actually added to the web page, as it
shows temporarely when I step through the method using firebug.

Any suggestions will be greatly apreciated (espcially if they
work ;-) )

Thanks,
Jarnis

--

You received this message because you are subscribed to the Google Groups 
"jQuery UI" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/jquery-ui?hl=.


Reply via email to