
function main() {
	calcsize();
	$("#bcg").show(); //only javascriptenabled users need to see this bcg
	//$("#fadeout").show();
	if (debug) {
		showsite();
	} else { 
		startlider();
	}
	$("#footer").click( function() {
		$("#content").slideUp(2000);
		$('#footer').hide();
	});
}

function showsite() {
	calcsize();
	$("#fadeout").show();
	$("#content").show();
	$('#footer').show();
}
function startlider() {
	calcsize();
	$("#fadeout").show();
	setTimeout("showcontents()",3000);
}
function slider() {
	calcsize();
	$("#fadeout").show();
	showcontents();
}
function calcsize() {
	var threshold = 1000;
	var browserWidth = $(window).width();
	if (browserWidth > threshold) { browserWidth = threshold; }
	var size = browserWidth / 100;
	$("body").css("font-size",size);
}
function showcontents() {
	$("#content").hide().slideDown(2000);
	setTimeout("$('#footer').slideDown(1000)",2000);
}
function info(id, target) {
	var data;
	var ids = target;
	target += "info";
	$(id).parent().children().each(function (i) {
		if (this.nodeName == "DIV") {
			data = this;
		}
	});
	$("#"+ids+" .redirectlink span").each(
		function( intIndex ){
			$(this).html("( &dArr; )");
			$(this).removeClass("currentinfo");
		}				
	); //= "(&dArr;)";
	if (data!="") {
		if ($("#"+target).html() != $(data).html()) {
			$("#"+target).html($(data).html());
			$("#"+target).hide();
			$("#"+target).slideDown(200);
			id.innerHTML = "( &uArr; )";
			//$(id).addClass("currentinfo");
		} else {
			$("#"+target).slideUp(200);
			$("#"+target).hide();
			$("#"+target).html("");
		}
	}
}
