/////////////////////////////////////////////////////////////////////////////
// what to expect div controls
/////////////////////////////////////////////////////////////////////////////
function whatToExpect() {
	document.getElementById('pdiv').style.width='700px';
	document.getElementById('pdiv').style.height='auto';
	moveDiv('pdiv',0,0);
	document.getElementById('pdiv').style.visibility = 'visible';
	document.getElementById('pdivBtn').focus();
}
function closePDiv() {
	document.getElementById('pdiv').style.visibility = 'hidden';
}
function openPageDiv(d, w) {
	document.getElementById(d).style.width=w+'px';
	document.getElementById(d).style.height='auto';
	moveDiv(d,0,0);
	document.getElementById(d).style.visibility = 'visible';
	document.getElementById(d+'Btn').focus();
}
function closePageDiv(d) {
	document.getElementById(d).style.visibility = 'hidden';
}

/////////////////////////////////////////////////////////////////////////////
// banner div controls
/////////////////////////////////////////////////////////////////////////////
	var num = 0;
	var ar = new Array();
//	ar[0] = "M1-14-creative-berlin.png";
	ar[0] = "M2b-14-SWQA-berlin.png";
	ar[1] = "M3-14-private-berlin.png";
	ar[2] = "M4-14-corporate-berlin.png";
	ar[3] = "M5-14-online-berlin.png";
	ar[4] = "M6-14-business-berlin.png";
	ar[5] = "M7-14-performance-berlin.png";
//	ar[6] = "M8-14-oracle-berlin.png";
	ar[6] = "M1-14-creative-berlin.png";
	ar[7] = "M8-14-oracle-berlin.png";
preload(ar);

function startBanner() {
	updateBanner();
	setInterval("updateBanner()", 7000);
}

function updateBanner() {
	// fade out and change text
	$j('#bannerText').animate({opacity: 'hide'}, 2000,
		function(){
		$j('#bannerText :first-child').attr("src","");
		$j('#bannerText :first-child').attr("src","./images/"+ar[num]);
	});
	// fade in
	$j('#bannerText').fadeIn(2000);
	// loop
	num++;
	if (num == ar.length) num = 0;
}

function preload(arrayOfImages) {
    $(arrayOfImages).each(function(){
        $('<img/>')[0].src = "./images/"+this;
        // Alternatively you could use:
        // (new Image()).src = this;
    });
}

function hotSpot() {
//alert("HotSpot!");
	window.location.href="index.php";
}



