	

	if (navigator.platform=="iPad"){
		alert("Thanks for visiting FunnyJuggler.com . This site currently is not configured for viewing on an iPad. We recommend using a computer.  We hope to have this issue fixed soon");
		document.getElementById(Content_Text).style.overflow="visible"
	}


		var myvisible = "1"
		var myelement = "event_0_detail"

		function showhidden(element){

			//alert("clicked");

			// first make sure any previously displayed records are hidden
				hideme(myelement)
		
			if (myvisible == element){
				hideme(myelement)
				myelement = element	
				}
			else{
				hideme(myelement)
				document.getElementById(element).style.display="block";
				myvisible =element
				myelement = element	
				}
			}

		function hideme(element){
			document.getElementById(element).style.display="none";
			myvisible = ""
			}





		function show_old_records(){
			alert("show_old_records is running ");
			var complete = false;
			
			alert(document.getElementById('event_0').style.display);
			var Displayinfo =document.getElementById('event_0').style.display
	
			alert("mystring ="+ Displayinfo);

			var mystring='event_7';
			alert("this works - " + document.getElementById(mystring).style.display);

			//alert("Loop exited.  Function Complete");
		}


//////////////////////////////////////////////

function mySubmit(){
		// edit next section for validation on individual forms.
		
 
		// test if user has entered their name
		if(document.myForm.elements("name").value==""||document.myForm.elements("name").value == null){
			alert("Name is a required Field.  Please include your name.");
			return false;
			}
 
		// test if user has entered their City
		if(document.myForm.elements("city").value==""||document.myForm.elements("city").value == null){
			alert("City is a required Field.  Please include your city.");
			return false;
			}
		// test if user has entered their name
		if(document.myForm.elements("prov").value==""||document.myForm.elements("prov").value == null){
			alert("Province/State is a required Field.  Please include your Province/State.");
			return false;
			}
		
		// test if user has entered a phone number
		if(document.myForm.elements("phone").value.length < 10){
			alert("Phone is a required field. Please be sure to include your phone number with area code.");
			return false;
			}
 
 
		// test if user has entered their email and if it is a valid email
		var emailAddress;
		var atSymb;
		var dotSymb;
		emailAddress = document.myForm.elements("email").value;
		atSymb = emailAddress.indexOf("@");
		dotSymb = emailAddress.indexOf(".",atSymb);
 
		if(emailAddress==""){ // this checks for blank field
			alert("Email is a required Field.  Please include your Email address.");
			return false;
			}
		// next check for valid email address
		else if(atSymb < 2 || dotSymb < atSymb + 3 || emailAddress.indexOf(" ")>-1 ){
			alert("Please verify that your E-mail address is a valid address");
			return false;
			}
		}
		// -->
				
			
	function photo_jiggle(container_name){
			
		
				document.getElementById(container_name).style.borderTop="4px solid black"; 
				document.getElementById(container_name).style.borderLeft="4px solid black";
				document.getElementById(container_name).style.borderBottom="2px solid black";
				document.getElementById(container_name).style.borderRight="2px solid black";
				}
	
	function photo_jiggle_off(container_name){
				document.getElementById(container_name).style.borderTop="2px solid black"; 
				document.getElementById(container_name).style.borderLeft="2px solid black";
				document.getElementById(container_name).style.borderBottom="4px solid black";
				document.getElementById(container_name).style.borderRight="4px solid black";
				}

	function photo_previous(ThisPhoto,PhotoCount){ // navagates to previous photo on photos page.
				alert("running photo_previous");
				document.getElementById('photo_'+ThisPhoto).style.display="none";
				ThisPhoto = ThisPhoto -1
				if(ThisPhoto < 0){
					ThisPhoto=PhotoCount
					}
				document.getElementById('photo_'+ThisPhoto).style.display="block";
				}

	function photo_next(ThisPhoto,PhotoCount){ // navagates to next photo on photos page.
				hideme('photo_' + ThisPhoto);
				alert("running photo_next");
				var MyElement = 'photo_' + ThisPhoto
				document.getElementById(MyElement).style.display="none";
				ThisPhoto = ThisPhoto + (1 *1)
				if(ThisPhoto > PhotoCount -1){
					ThisPhoto=0
					}
				MyElement = 'photo_' + ThisPhoto
				document.getElementById(MyElement).style.display="block";
				}
	

		

