borjour = {
  
  dialogShow: function(content)
  {
    jQuery('#ajax-content').html(content).dialog({title: 'Borjour', modal: true, minHeight: 20, width: 'auto', height: 'auto', maxHeight: 600 });
    borjour.dialogCenter();
  },
  
  dialogCenter: function()
  {
    jQuery('#ajax-content').dialog('option', 'position', 'center');
  },
  
  activateDialogLink: function()
  {
    jQuery('#ajax-content a.dialog-link').click(function() {
      jQuery('#ajax-content .indicator').show();
      jQuery.ajax({
        type: 'GET',
        cache: false,
        dataType: 'html',
        success: function(data, textStatus)
        {
          jQuery('#ajax-content').html(data);
        },
        complete: function(XMLHttpRequest, textStatus)
        {
          borjour.dialogCenter();
        },
        url: this.href
      });
      
      return false;
    });
  },
  
  showDialog: function()
  {
    jQuery('#ajax-content').parent().show();
  },
  
  hideDialog: function()
  {
    jQuery('#ajax-content').parent().hide();
  }
  
};
