$(document).ready(function() {

//	$('#cycle').cycle({
//		fx: 'fade'
//	});

//	$('figure.gallery-item a').attr('rel','gallery');
//	$('figure.gallery-item a[rel="gallery"]').fancybox();

// paginazione congressi
	$('.page-num-1').show();
	$('.year_select a').click(function(event){
		event.preventDefault();
		$this = $(this)
		page_num = $this.html();
		$('.congresso').hide();
		$('.page-num-'+page_num).show();
	});

// iscrizione congressi
	function getURLParameter(name) {
	    return decodeURI(
		(RegExp(name + '=' + '(.+?)(&|$)').exec(location.search)||[,null])[1]
	    );
	};
	
	$('input[name="congress-id"]').attr("value", getURLParameter('cong_id'));
	$('input[name="congress-name"]').attr("value", $('#congress-title').text());
});

