function autoFill(id, text, startColor, endColor)
{
	$(id).css({ color: startColor }).attr({ value: text }).focus(function()
	{
		if($(this).val()==text)
		{
			$(this).val("").css({ color: endColor });
		}
	}).blur(function()
	{
		if($(this).val()=="")
		{
			$(this).css({ color: startColor }).val(text);
		}
	});		
}

$(document).ready(function()
{
	autoFill($("#footer_search"), "Search the Executive Council", "#999", "#111");
	autoFill($("#events_search"), "Search Events", "#999", "#111");
	autoFill($("#firstname"), "Bob", "#999", "#111");
	autoFill($("#lastname"), "Johnston", "#999", "#111");
	autoFill($("#email"), "i.e. bob@execcouncil.org", "#999", "#111");
	
	var startHeight = '53px';
	$('.showhidebox').css({ 'height' : startHeight });
	$('a.biodrop').toggle(function()
	{
		var endHeight = parseInt($(this).parent().prev().find('.biobox').height() + 5) + 'px';
		$(this).parent().prev().animate({ 'height' : endHeight });
		$(this).html('SHORT BIO');
		return false;
	},function()
	{
		$(this).parent().prev().animate({ 'height' : startHeight });
		$(this).html('FULL BIO');
		return false;
	});
});