All the information you need is located directly on the user interface documentation page, bottom to bottom on the tabs labeled “Options” and “Methods”. These guys are your friends and will tell you (almost) everything the widget can do. For instance,
<div id="dialog" title="Basic dialog"> <p>This is the default dialog which is useful for displaying information. The dialog window can be moved, resized and closed with the 'x' icon.</p> </div> ... <a href="" onclick="openDialog('Peter Smith', '<p>Peter Smith likes dirt bike riding, mountain climbing and punk music.</p>'); return false;">Peter Smith</a> ... <script type="text/javascript"> $(document).ready( function() { $("#dialog").dialog({ autoOpen: false, modal: true }); }); function openDialog(title, text) { $("#dialog").html(text).dialog('option','title',title).dialog('open'); } </script>
source share