title: jquery ui Dialog: cannot call methods on dialog prior to initialization
body: <p>I have an app on jquery 1.5 with dialogs worked fine.
  While I have a lot of .live handlers, I changed this to .on.
  For that, I have to update jquery (now 1.8.3 an jquerui 1.9.1).</p>
  
  <p>Now, I got: <code>Error: cannot call methods on dialog prior to initialization; attempted to call method 'close'</code></p>
  
  <p>Following is the code:</p>
  
  <p>Javascript</p>
  
  <pre><code>var opt = {
          autoOpen: false,
          modal: true,
          width: 550,
          height:650,
          title: 'Details'
  };
  
  $(document).ready(function() {
  $("#divDialog").dialog(opt);
      $("#divDialog").dialog("open");
  ...    
  </code></pre>
  
  <p>html code</p>
  
  <pre><code>&lt;div id="divDialog"&gt;
  &lt;div id="divInDialog"&gt;&lt;/div&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>Any idea why this might be happening?</p>