function tab_show( show, hide )
{
	li_show = jQuery( '#' + show );
	li_hide = jQuery( '#' + hide );
	
	li_show.addClass( 'selected' );
	li_hide.removeClass( 'selected' );
	
	id_show = li_show.attr( 'rel' );
	id_hide = li_hide.attr( 'rel' );
	
	carousel_show = jQuery('#chained_' + id_show).data('jcarousel');
	carousel_hide = jQuery('#chained_' + id_hide).data('jcarousel');
	
	carousel_hide.stopAuto();
	jQuery( '#block-' + id_hide ).css( 'display', 'none' );
	carousel_show.startAuto();
	jQuery( '#block-' + id_show ).css( 'display', 'block' );
}
function tab_article_show( show, hide )
{
	li_show = jQuery( '#' + show );
	li_hide = jQuery( '#' + hide );
	
	li_show.addClass( 'selected' );
	li_hide.removeClass( 'selected' );
	
	id_show = li_show.attr( 'rel' );
	id_hide = li_hide.attr( 'rel' );
	
	jQuery( '#block-' + id_hide ).css( 'display', 'none' );
	jQuery( '#block-' + id_show ).css( 'display', 'block' );
}
function openEventFrame( node_id )
{
	Shadowbox.init();
	Shadowbox.open({
        player:'iframe', 
        title:'Evenement agenda', 
        content:'/comexposium/event/' + node_id,
        height:     150,
        width:      480
    });
}

$(function() {

	$('#navigation ul.navigation_niv_2').hover( 
		function(e) {
			$(this).prev().toggleClass('hover');
		}
	);
	
	var al = $('.article_list .item');
	
	if (al.length) {
		$('.article_list .item:odd').addClass('odd');
	}
	
});
