//script img  HP
function ImgHp() {
	var testo = new Array();
	//testo[0] = "<img src='img/imgKobe0.jpg' width='553' height='245' border='0'>"
	testo[1] = "<img src='img/imgKobe1.jpg' width='553' height='245' border='0'>"
	testo[2] = "<img src='img/imgKobe2.jpg' width='553' height='245' border='0'>"
	//.....	
	//document.write(testo[parseInt("0"+(Math.random()*17+1))]);
	document.write(testo[Math.floor(Math.random()*2+1)]); // a random number between 1 to 105 is generated.
	//In conclusion, random numbers are only purely random if you transform them correctly. 
	//Otherwise you get skewed and unexpected results. Use: Math.floor(Math.random()*max+1) to get numbers between 1 and max.
}
// fine script img Grande HP


// Esempio code:
//  
// Random images aid in making a page look unique from others in the same template. 
//The following example contains images of five of the most popular search engines and their logos. 
//Each time the page is refreshed the script will select a random number from one to five 
//and dynamically write the appropriate image from an array to the browser. 
// 
//•View the Output  
// •Text View  
//•Print View  
//  •Mail this Link  
//     •Download the Code  
// 
//
//<html>
//<title>CodeAve.com(JavaScript:Random Images)</title>
//<body bgcolor="#FFFFFF">
//<center>
//
//<script language="JavaScript">
//<!--
// // Create arrays to contain all the values 
// // for image locations
//
//image = new Array
//
//image[1]="http://us.yimg.com/images/yahoo.gif"
//image[2]="http://www.excite.com/mesp/images/excite/new_logo-180.gif"
//image[3]="http://a284.g.akamai.net/7/284/987/000/lygo.com/ly/i/lyguide.gif"
//image[4]="http://cnet.com/Images/Headers/cnet-1-title.gif"
//image[5]="http://webcrawler.com/img/web/hdr/home_header.gif"
//
// Create a random number between 1 and five
//random_num = (Math.round((Math.random()*4)+1))
//
//
// Write the image tag with a random array element
//document.write("<img src=\"" + image[random_num] + "\">");
//
//-->
//</script>
//</center>
//
//</body>
//</html> 
 

 

