Array.prototype.in_array = function(p_val) {
for(var i = 0, l = this.length; i < l; i++) {
if(this[i] == p_val) {
return true;
}
}
return false;
}

function set_cookie(c_name, value, expiredays)
{
var exdate = new Date();

exdate.setDate(exdate.getDate() + expiredays);
document.cookie = c_name + "=" + escape(value) + ((expiredays==null) ? "" : ";expires=" + exdate.toGMTString());
}

function get_cookie(c_name)
{
if (document.cookie.length > 0)
{
c_start=document.cookie.indexOf(c_name + "=");

if (c_start != -1)
{
c_start = c_start + c_name.length + 1;
c_end = document.cookie.indexOf(";", c_start);
if(c_end==-1)
c_end=document.cookie.length;

return unescape(document.cookie.substring(c_start, c_end));
}
}

return "";
}


jQuery(document).ready(function(){
	jQuery("a[rel^='prettyPhoto']").prettyPhoto({
		animationSpeed: 'normal', /* fast/slow/normal */
		padding: 40, /* padding for each side of the picture */
		opacity: 0.65, /* Value betwee 0 and 1 */
		showTitle: false, /* true/false */
		allowresize: true, /* true/false */
		counter_separator_label: '/', /* The separator for the gallery counter 1 "of" 2 */
		theme: 'dark_rounded', /* light_rounded / dark_rounded / light_square / dark_square */
		callback: function(){}
	});
	
	if(get_cookie('has_visited_homepage') != 'yes')
	{
		set_cookie('has_visited_homepage', 'yes', 5);
		setTimeout("jQuery('#intro-swf').click();", 1000);
	}
});

