// $Id: nice_menus.js,v 1.17 2009/03/24 16:22:28 add1sun Exp $

// This uses Superfish 1.4.8
// (http://users.tpg.com.au/j_birch/plugins/superfish)

// Add Superfish to all Nice menus with some basic options.
$(document).ready(function() {

/*Auto Box Complete*/
   
   
            
    //includes/ajax.php?type=contactsearch&uid='+$('#pid').val()    
  
     
  /*End Auto Box Complete*/
  
  $(".contact" ).each(function() {
          $(this).css({'height':$(this).height()});
       });
  $(".contact1" ).each(function() {
          $(this).css({'height':$(this).height()});
       });
  
  $(".contact1").hide();
   
  $('ul.nice-menu').superfish({
    // Add the legacy hover class added for IE.
    hoverClass: 'ie-over',
    // Disable generation of arrow mark-up.
    autoArrows: false,
    // Disable drop shadows.
    dropShadows: false,
    // Mouse delay.
    delay: Drupal.settings.nice_menus_options.delay,
    // Animation speed.
    speed: Drupal.settings.nice_menus_options.speed
  });
  $('#datepicker').datepicker({
            changeMonth: true,
            changeYear: true,dateFormat: 'dd/mm/yy'   
  });
  $('#datepicker2').datepicker({
            changeMonth: true,
            changeYear: true,dateFormat: 'dd/mm/yy'
  });
  // Add in Brandon Aaron’s bgIframe plugin for IE select issues.
  // http://plugins.jquery.com/node/46/release
  $('ul.nice-menu').superfish().find('ul').bgIframe({opacity:false});
  /*
  $('.fg-button').hover(
            function(){ $(this).removeClass('ui-state-default').addClass('ui-state-focus'); },
            function(){ $(this).removeClass('ui-state-focus').addClass('ui-state-default'); }
        );
        
        // MENUS        
        $('#flat').menu({ 
            content: $('#flat').next().html(), // grab content from this page
            showSpeed: 400 
        });
        
        $('#hierarchy').menu({
            content: $('#hierarchy').next().html(),
            crumbDefaultText: ' '
        });
        
        $('#hierarchybreadcrumb').menu({
            content: $('#hierarchybreadcrumb').next().html(),
            backLink: false
        });
        
        // or from an external source
        $.get('menuContent.html', function(data){ // grab content from another page
            $('#flyout').menu({ content: data, flyOut: true });
        }); 
       */
  
   
});

