// Global Variables

	var thisEvent = 0;
	var thisSponsor = 0;


function RotateEvent()
	{
	EventImages = new Array("assets/IMG Event0.jpg","assets/IMG Event1.jpg","assets/IMG Event2.jpg","assets/IMG Event3.jpg","assets/IMG Event4.jpg","assets/IMG Event5.jpg")
	ImageCount = EventImages.length

	if (document.images)
		{
		thisEvent = thisEvent + 1
			if (thisEvent == ImageCount)
				{
				thisEvent = 0
				}
		document.Event.src=EventImages[thisEvent]
		setTimeout("RotateEvent()", 5 * 1000)
	  	}
	}


function RotateSponsor()
	{
	SponsorImages = new Array("assets/IMG Event0.jpg","assets/IMG Event1.jpg","assets/IMG Event2.jpg","assets/IMG Event3.jpg","assets/IMG Event4.jpg","assets/IMG Event5.jpg")
	ImageCount = SponsorImages.length

	if (document.images)
		{
		thisSponsor = thisSponsor + 1
			if (thisSponsor == ImageCount)
				{
				thisSponsor = 0
				}
		document.Sponsor.src=SponsorImages[thisSponsor]
		setTimeout("RotateSponsor()", 4 * 1000)
	  	}
	}









function howtobreak()
	{
	var i=0
	for (i = 0; i <= 10; i++)
		{
		if (i==3)
			{
			break;
			}
		document.write("break loop " + i + "<br>");
		}
	document.write("loop is \"Broken\" on loop " + i + " \& what else?");
	}


function howtocontinue()
	{
	var i=0
	for (i = 0; i <= 10; i++)
		{
		if (i==3 || i==6)
			{
			continue;
			}
		document.write("<h4>Continue Loop " + i + "</h4>");
		}
	}


function forinfootie()
	{
	var x;
	var footieplayers = new Array();
		footieplayers[0] = "Platini FRA"
		footieplayers[1] = "Zidane FRA"
		footieplayers[2] = "Pele BRA"
		footieplayers[3] = "Ronaldo BRA"
		footieplayers[4] = "Charlton ENG"
		footieplayers[5] = "Beckham ENG"
		footieplayers[6] = "Rossi ITA"
		footieplayers[7] = "Maldini ITA"

		for (x in footieplayers)
			{
			document.write("<h6>" + footieplayers[x] + "</h6>");
			}
	}


function trycatch()
	{
	var txt="";

	try
		{
		abbblert("Welcome guest!")         // error caused by spelling of alert
		}
		catch(err)
		{
		txt="There was an error on this page.\n\n"
		txt+="Error description: " + err.description + "\n\n"
		txt+="Click OK to continue viewing this page.\n\n"
		txt+="or Cancel to return to the home page.\n\n"
		if(!confirm(txt))
			{
			document.location.href="http://www.w3schools.com/"
			}
		}
	}


function trythrowcatch()
	{
	var x=prompt("Please enter a number between 0 and 10:","")

	try
		{
		if (x > 10)
		throw "Error1"
		else
			if (x < 0)
			throw "Error2"
			else
				if(isNaN (x))
				throw "Error3"
		}
	catch(error)
		{
		if (error=="Error1")
			alert("Entry is too HIGH")
		if(error == "Error2")
			alert("Entry is too LOW")
		if(error == "Error3")
			alert("Entry is NOT a number")
		}
	}


function standardErrorHandler(msg, url, line)
	{
	var txt=""

	txt="There was an error on this page.\n\n"
	txt+="Error: " + msg + "\n"
	txt+="URL: " + url + "\n"
	txt+="Line: " + line + "\n\n"
	txt+="Click OK to continue.\n\n"
	alert(txt)
	return true
	}

function message()
	{
	adddlert("Welcome guest!")
	}










