// FANCYBOX
$(document).ready(function() {
	$(".general-image").fancybox({
		'padding'		: 0,
		'transitionIn'		: 'none',
		'transitionOut'		: 'none',
		'scrolling'		: 'no',
		'hideOnContentClick' : true
	});
	$(".zoom-image").fancybox({
                'titlePosition'	: 'over',
		'padding'		: 0,
		'transitionIn'		: 'none',
		'transitionOut'		: 'none',
		'scrolling'		: 'no',
		'hideOnContentClick' : true
	});
	$(".youtube-video").fancybox({
		'padding'		: 0,
		'transitionIn'		: 'none',
		'transitionOut'		: 'none',
		'scrolling'		: 'no'
	});

	$("a[rel=image-group1]").fancybox({		
		'transitionIn'		: 'none',
		'transitionOut'		: 'none',
		'titlePosition' 	: 'over',
		'titleFormat'		: function(title, currentArray, currentIndex, currentOpts) {
		return '<span id="fancybox-title-over">Image ' + (currentIndex + 1) + ' / ' + currentArray.length + (title.length ? ' &nbsp; ' + title : '')+'</span>';		}
	});
	$("a[rel=image-group2]").fancybox({		
		'transitionIn'		: 'none',
		'transitionOut'		: 'none',
		'titlePosition' 	: 'over',
		'titleFormat'		: function(title, currentArray, currentIndex, currentOpts) {
		return '<span id="fancybox-title-over">Image ' + (currentIndex + 1) + ' / ' + currentArray.length + (title.length ? ' &nbsp; ' + title : '')+'</span>';		}
	});

});

// *** COOKIE FOR PLAYER ***
function Set_Cookie( name, value, expires, path, domain, secure ){
   var today = new Date();
   today.setTime( today.getTime() );
   if ( expires ){
      expires = expires * 1000 * 60 * 60 * 24;
   }
   var expires_date = new Date( today.getTime() + (expires) );
   document.cookie = name + "=" +escape( value ) +
   ( ( expires ) ? ";expires=" + expires_date.toGMTString() : "" ) +
   ( ( path ) ? ";path=" + path : "" ) +
   ( ( domain ) ? ";domain=" + domain : "" ) +
   ( ( secure ) ? ";secure" : "" );
}
// FOR PLAYER
Set_Cookie( 'cookiecheck', '1', 30, '/', '', '' );
