	function getWidth() {
		var myWidth = 0;
			if( typeof( window.innerWidth ) == 'number' ) {
	    			//Non-IE
	    			myWidth = window.innerWidth;
			}
			else if( document.documentElement && ( document.documentElement.clientWidth || document.documentElement.clientHeight ) )
			 {
	    			//IE 6+ in 'standards compliant mode'
	    			myWidth = document.documentElement.clientWidth;
	  		}
			else if( document.body && ( document.body.clientWidth || document.body.clientHeight ) )
			{
	    			//IE 4 compatible
	    			myWidth = document.body.clientWidth;
	  		}
		return myWidth;
	}

	function getHeight() {
		var myHeight = 0;
			if( typeof( window.innerWidth ) == 'number' ) {
	    			//Non-IE
	    			myHeight = window.innerHeight;
			}
			else if( document.documentElement && ( document.documentElement.clientWidth || document.documentElement.clientHeight ) )
			 {
	    			//IE 6+ in 'standards compliant mode'
	    			myHeight = document.documentElement.clientHeight;
	  		}
			else if( document.body && ( document.body.clientWidth || document.body.clientHeight ) )
			{
	    			//IE 4 compatible
	    			myHeight = document.body.clientHeight;
	  		}
		return myHeight;
	}

	SBarx = function(message){
		lower=0;
		numvalue = parseInt(document.barformx.indexx.value);
		if (numvalue>120) lower=numvalue-120;
		document.barformx.barx.value = message.substring(lower,numvalue);
		numvalue++;
		document.barformx.indexx.value = numvalue;
	}

	function PulminoDisappears()
	{
		offset = 300;
		centerOfBrowser = Math.round(getWidth()/2);
		endOfBrowser = getWidth();
		lastPosition = endOfBrowser-centerOfBrowser+offset;
		new Effect.Move('ciao',{ x: lastPosition, y: 0 });
		setTimeout('document.getElementById("ciao").style.visibility="hidden";', 2500);
	}
	
	Pulmino = function(){
		offset = 300;
		centerOfBrowser = Math.round(getWidth()/2);
		centerOfBrowser = centerOfBrowser + offset;
		endOfBrowser = getWidth();
		verticalAlignment = Math.round(getHeight()/2);
		//centerOfBrowser = 800;
		document.getElementById("ciao").style.visibility="visible";
		document.getElementById("ciao").style.left="-300px";
//		document.getElementById("ciao").style.top=verticalAlignment+"px";
		new Effect.Move('ciao',{ x: centerOfBrowser, y: 0 });
		setTimeout('PulminoDisappears()', 4500);
	}

	function changeBGImage(){	
				num = 2;
				do{
					pic1=Math.random();
				
					pic1=pic1*num;
					
					pic1=Math.round(pic1);
		
				}while ( pic1==0 )
				
				
			
				if (pic1<10) pic1="0"+pic1;
		
				newImage = "url(20th/backgrounds/"+pic1+".jpg)";
				document.getElementById("maintable").style.backgroundImage=newImage;
				//maintable.background="20th/backgrounds/"+pic1+".jpg";
				
	}

	function changeBGImageNew(){	
						
				newImage = "url('newsite/bg.jpg')";
				document.getElementById("maintable").style.backgroundImage=newImage;
				//maintable.background="20th/backgrounds/"+pic1+".jpg";
				
	}
