$(document).ready(function() { $(\"#create-user\").button().click(function() { $(\"#dialog-form\").load(\'test.html\').dialog({ modal:true, });
for closing the dialog you can use,
$("#dialog-form").dialog('close');