Cufon.replace('.mainleft #list h1', { fontFamily: 'Myriad Pro', hover:true });
Cufon.replace('.mainleft h1', { fontFamily: 'Myriad Pro', hover:true });
Cufon.replace('.mainleft2 #list h1', { fontFamily: 'Myriad Pro', hover:true });
Cufon.replace('.mainleft2 h1', { fontFamily: 'Myriad Pro', hover:true });
Cufon.replace('.maincenter h1', { fontFamily: 'Myriad Pro', hover:true });
Cufon.replace('.mainright h1', { fontFamily: 'Myriad Pro', hover:true });
Cufon.replace('.banner h2', { fontFamily: 'Myriad Pro', hover:true });
Cufon.replace('h2', { fontFamily: 'Myriad Pro'});

function searchform()
{
  document.searchform.submit();
}

function preloadImages(imgs){
	
	var picArr = [];
	
		for (i = 0; i<imgs.length; i++){
			
				picArr[i]= new Image(100,100); 
				picArr[i].src=imgs[i]; 

			
			}
	
	}

var $j = jQuery.noConflict();
		$j(document).ready(function(){
		$j('.menu-nav li').hover(
			function() {
				$j(this).addClass("active");
				$j(this).find('.ulwrapper').stop(false, true).fadeIn('slow');
				$j(this).find('.ulwrapper .ulwrapper').stop(false, true).fadeOut('fast');
			},
			function() {
				$j(this).removeClass("active");        
				$j(this).find('div').stop(false, true).fadeOut('fast');
			}
		);

		$j('.ulwrapper').hover(
			function() {
				$j('.parent').addClass("active_tab");
			},
			function() {
				$j('.parent').removeClass("active_tab");        
			}
		);
			
		jQuery(".yeardescr").hide(); 	
		jQuery(".yeardescr").first().show(); 	
		
		
		$j("h3.dates").hover(
			function() {
		$j(this).addClass("underline");
			},
			function() {
				$j(this).removeClass("underline");        
			}
		);
				
		jQuery("h3.dates").click(function(){						  
		jQuery(this).next("h4.dates").next(".yeardescr").slideToggle();
			});		
	 		
		$j("a[rel='layer']").fancybox({
				'transitionIn'		: 'elastic',
				'transitionOut'		: 'none',
				'titleShow'		: true
			});	
		
	});
		
	preloadImages([
		'images/drop_bgt.png', 
		'images/drop_bgs.png', 
		'images/menu_bg_right.png']);

		$j(function() {
		// run the code in the markup!
		$j('table pre code').not('#skip,#skip2').each(function() {
			eval($j(this).text());
		});
		
	});
	 

