$(document).ready(function(){

	if($.browser.name == 'chrome'){ $('body').addClass('chrome'); }

	$('#home_flash').flash({
	    src: '/swf/technology.swf',
	    width: 210,
	    height: 210,
		wmode: 'transparent'
	});
	
	$('#home_flash_top_left').flash({
	    src: 'http://www.youtube.com/v/gqGrNj5DHRI&hl=en_US&fs=1&',
	    width: 260,
	    height: 210,
		wmode: 'transparent'
	});
	
	$('#home_flash_top_right').flash({
	    src: 'http://www.youtube.com/v/fQsIhhD2xe0&hl=en_US&fs=1&',
	    width: 260,
	    height: 210,
		wmode: 'transparent'
	});

/*
	$('#media').flash({
    src: '/swf/bioreactor.swf',
    width: 392,
    height: 334,
		wmode: 'transparent'
	});
*/


	$('#tech_video').flash({
    src: '/swf/cbdi_vessle_vid.swf',
    width: 295,
    height: 218,
		wmode: 'transparent'
	});


	$('#video_muscle').flash({
    src: '/swf/video_muscle.swf',
    width: 295,
    height: 218,
		wmode: 'transparent'
	});


	$('#video_valve').flash({
    src: '/swf/video_valve.swf',
    width: 295,
    height: 218,
		wmode: 'transparent'
	});




//	$('#content a').hover(function(){ flashColor(this); }, function(){ revertColor(this); });




});


function set_cookie( name, value, exp_y, exp_m, exp_d, path, domain, secure )
{
  var cookie_string = name + "=" + escape ( value );

  if ( exp_y )
  {
    var expires = new Date ( exp_y, exp_m, exp_d );
		var myDate = "; expires=" + expires.toGMTString();
    cookie_string += myDate;
  }

  if ( path )
        cookie_string += "; path=" + escape ( path );

  if ( domain )
        cookie_string += "; domain=" + escape ( domain );
  
  if ( secure )
        cookie_string += "; secure";
  
  document.cookie = cookie_string;
}


function get_cookie ( cookie_name )
{
  var results = document.cookie.match ( '(^|;) ?' + cookie_name + '=([^;]*)(;|$)' );

  if ( results )
    return ( unescape ( results[2] ) );
  else
    return null;
}

/*
function flashColor(el)
{
        $(el).animate({ color:'#0066cc' },200);
				setTimeout(function(){ revertColor(el); }, 5000);
}

function revertColor(el)
{
 	setTimeout(function(){ $(el).animate({ color:'#EC8818' },200); }, 100);
}

*/