$(document).ready(function() {
	
	// book summary zebra stripes
	$(".book-summary:odd").addClass("dark");


	// roadmap table zebra stripes and hover effect
	$("table.marketing-roadmap tr:odd").addClass("dark");

	$("table.marketing-roadmap td").hover(function() {
		$(this).addClass("hover");
	},function() {
		$(this).removeClass("hover");
	});  


	// fancybox image preview
	$("a.fancy-img").fancybox({
		'titleShow'		: false,
		'transitionIn'	: 'elastic',
		'transitionOut'	: 'elastic'
	});


	// fancybox iframe preview
	$("a.fancy-iframe").fancybox({
		'width'				: '75%',
		'height'			: '90%',
		'autoScale'			: false,
		'transitionIn'		: 'elastic',
		'transitionOut'		: 'elastic',
		'type'				: 'iframe'
	});
	
	// fancybox video preview	
	$("a.fancy-video").fancybox({
		'width'				: 665,
		'height'			: 505,
		'autoScale'			: false,
		'transitionIn'		: 'elastic',
		'transitionOut'		: 'elastic',
		'type'				: 'iframe'
	});
});

/*
 * Used by Corporate site home page and mini-videos register page
 * to allow anchor tag to be used as a submit button. This allows 
 * user to click the button OR press enter on their keyboard
 */
function submitEnrollmentForm() {
	document.enrollmentform.submit();
}
