﻿$(document).ready(function(){
	
	// Needed for IE6 so the images display properly
	$(".series-content .item img").css("float","left");
	
	// Fix PNG transparency for IE6
	$(document).pngFix();
	
	// Cycle slides on startpage
	$(".slides").cycle({
		timeout: 2000, // Time between slides
		speed: 1800, // Length of transition
		pause: true // Pause on hover
	});
			
	// All input fields assigned with the class 'default' will
	// get their default values hidden when clicked, and reset again
	// if the user leaves the field empty or hasnt changed anything
	$("input.default").each(function() {
		var defaultVal = $(this).val();	
		if (!($(this).val()))
			$(this).val(defaultVal);
		$(this).focus(function() {
			
			if($(this).val() == defaultVal)
				$(this).val("");
		});
		$(this).blur(function(){
			if ($(this).val() == "")
				$(this).val(defaultVal);
		});
	});
});
