Dialog with no selector

Dialog with no selector

Dear Everyone, 

I'm building a jQuery UI Dialog for the first time using the following line of code:

  1.  $("#demo").text('Are you sure ?').dialog({width: 250});                      
But attaching the dialog to an html element is causing problems. All I want is a confirmation dialog box independent of the page html. Is this even possible with jQuery UI ? Thank you all in advance.