title: Liferay 6.2 modal add callback on close
body: <p>I need to excute a generic function (console.log) on closing (on hide) modal window created with this javascript code:</p>
  
  <pre><code>    YUI().ready(function(A) {
          YUI().use('aui-base','liferay-util-window', function(A) {
              Liferay.Util.Window.getWindow(
                  {
                      title : title,
                      uri: url,
                      dialog: {
                          cache: false,
                          modal: true
                      }
                  }
              ).on('hide', function() {
                    console.log("Modal closed")});
  
          });
      });
  </code></pre>
  
  <p>'<em>url</em>' and '<em>title</em>' are two variables passing from code above.<br>
  It doesn't work.<br>
  Any suggestion?</p>