$(document).ready(function() {
	$("#cv_full").hide();
	
	$(".cv_summary_link").click(function() {
		$("#cv_full").hide();
		$("#cv_summary").show();
		$(".cv_summary_link").addClass('current');
		$(".cv_full_link").removeClass('current');
		
		return false;
	});
	
	$(".cv_full_link").click(function() {
		$("#cv_summary").hide();
		$("#cv_full").show();
		$(".cv_full_link").addClass('current');
		$(".cv_summary_link").removeClass('current');
		
		return false;
	});
	
	//$("#showreelbox").hide();
	
	$("#showreel_link").click(function() {
		$("#showreellinkbox").hide("slow");
		//$("#showreelbox").show("slow");
		
		return false;
	});
	
	$("#showreel_link_hide").click(function() {
		$("#showreellinkbox").show("slow");
		$("#showreelbox").hide("slow");
		
		return false;
	});
});

function focusName(id) {
	document.getElementById('artist-'+id).style.textDecoration='underline';
}

function focusOutName(id) {
	document.getElementById('artist-'+id).style.textDecoration='none';
}

function doCheck(f){
				
	if(!f.showreel_name.value){
		alert("Please fill in a name.");
		f.showreel_name.focus();
		return false;
	}
	if(!f.showreel_profession.value){
		alert("Please fill in a profession.");
		f.showreel_profession.focus();
		return false;
	}
	if(!f.showreel_email.value){
		alert("Please fill in email.");
		f.showreel_email.focus();
		return false;
	}
	else if(!isEmail(f.email.value)){
		alert("Please fill in a correct email.");
		f.showreel_email.focus();
		return false;			
	}
}

function doFocus(){
	try{
		document.formen.name.focus();
	}
	catch(err){
	}
}