// <![CDATA[

$(document).ready(function() {
	$('.default-value').each(function() {
		var default_value = this.value;
	//     $(this).css('color', '#666'); // this could be in the style sheet instead
		$(this).focus(function() {
			if(this.value == default_value) {
				this.value = '';
	//             $(this).css('color', '#333');
			}
		});
		$(this).blur(function() {
			if(this.value == '') {
	//             $(this).css('color', '#666');
				this.value = default_value;
			}
		});
	});
	// sidebars
	$('.shadow_box h2').click(function(){
		$('.shadow_box div.inner').slideToggle(500);
		return false;
	});

	// tabbed boxes
	$('.tab_box div.section').hide();
	$('.tab_box div.section:first').show();
	$('.tab_box ul li:first').addClass('active');
	
	$('.tab_box ul li a').not('.tab_box ul li a.exbox').click(function(){
		$('.tab_box ul li').removeClass('active');
		$(this).parent().addClass('active');
		var currentTab = $(this).attr('href');
		$('.tab_box div.section').hide();
		$(currentTab).show();
		return false;
	});
			
	// flyouts
	$('a.flyout').click( function(event) {
		window.open($(this).attr("href"), 'flyout', "width=700,height=500,scrollbars=yes,menubar=yes,resizable=yes,toolbar=yes");
		event.preventDefault();
	});
	
	// data tables formatting
	$('table.data tr:odd').not('table.data tr.heading').addClass('odd');
	$('table.data tr:even').not('table.data tr.heading').addClass('even');
});


// ]]>


