$(document).ready(function(){
	$("a.youtube").click(function() {
		$.fancybox({
				'padding'		: 0,
				'autoScale'		: false,
				'transitionIn'	: 'none',
				'transitionOut'	: 'none',
				'title'			: this.title,
				'width'		: 680,
				'height'		: 495,
				'href'			: this.href.replace(new RegExp("watch\\?v=", "i"), 'v/'),
				'type'			: 'swf',
				'swf'			: {
				   	 'wmode'		: 'transparent',
					'allowfullscreen'	: 'true'
				}
			});
		return false;
	});
	$('.dropdowns h4').each(function() {
	    var tis = $(this), state = false, answer = tis.next('div').hide();
	    tis.click(function() {
	      state = !state;
	      answer.slideToggle(state);
	      tis.toggleClass('active',state);
	    });
	  });
	$('.research_dropdown h2').each(function() {
	     var tis = $(this), state = false, answer = tis.next('div').hide();
	     tis.click(function() {
	       state = !state;
	       answer.slideToggle(state);
	       tis.toggleClass('active',state);
	     });
	 });
	 if ($.cookie("textsize")) {
	 	var newsize = $.cookie("textsize") + 'px';
	 	$('body').css("font-size", newsize);
	 }
});


$(document).ready(function(){  
    //set the starting bigestHeight variable  
    var biggestHeight = 0;  
    //check each of them  
    $('.child_listing_individual').each(function(){  
        //if the height of the current element is  
        //bigger then the current biggestHeight value  
        if($(this).height() > biggestHeight){  
            //update the biggestHeight with the  
            //height of the current elements  
            biggestHeight = $(this).height();  
        }  
    });  
    //when checking for biggestHeight is done set that  
    //height to all the elements  
    $('.child_listing_individual').height(biggestHeight);  
  
});  


