// <![CDATA[
	var subMenuDisplayed
	function subMenu(main,id,show){
		
		var mainMenu = document.getElementById(main);
		var mainMenuSub = mainMenu.childNodes;
		var mainMenuSubLen = mainMenuSub.length;
	
		//Loop through all the sub ul elements of 'main' and hide
		for(var x=0;x<mainMenuSubLen;x++){
			var subMenu = mainMenuSub[x].childNodes;
			var subMenuLength = subMenu.length;
			
			for(var xy=0;xy<subMenuLength;xy++){
				if(subMenu[xy].nodeName=='UL'){
					document.getElementById(subMenu[xy].id).style.display='none';
				}
			}
		}		
		
		//Display the sub menu and parent item(s) 'ul'
		var parentMenu = document.getElementById('ul_'+ id).parentNode;
		var count = 1;
		while (parentMenu.getAttribute('id') != 'left_menu'){
			if (parentMenu.tagName == 'UL'){
				parentMenu.style.display='block';
			}
			parentMenu = parentMenu.parentNode;			
			count++;
		}
		document.getElementById('ul_'+ id).style.display='block';
		
		subMenuDisplayed = id;

		return false;
	}

	checkDefault = function(objInput, strValue){
		if(objInput.value == strValue){
			objInput.value = "";
		}
	}
	checkNew = function(objInput, strValue){
		if(objInput.value == ""){
			objInput.value = strValue;
		}
	}

	function addLoadEvent(func) {
	    var oldonload = window.onload;
	    if (typeof window.onload != 'function') {
	        window.onload = func;
	    } else {
	        window.onload = function() {
	            if (oldonload) {
	                oldonload();
	            }
	            func();
	        }
	    }
	}

	function showYoutube(){
		document.getElementById("youtube_bg").style.display='block';
		document.getElementById("youtube_bg").style.zIndex='100';
		document.getElementById("youtube").style.display='block';
		document.getElementById("youtube_bg").style.zIndex='101';
	}

	function hideYoutube(){
		document.getElementById("youtube").style.display='none';
		document.getElementById("youtube_bg").style.display='none';
	}

function Popup(mypage, name, width ,height){
	w = width
	h = height
	myname=name
	var winl = (screen.width - w) / 2;
	var wint = (screen.height - h) / 2;
	winprops = 'height='+h+',width='+w+',top='+wint+',left='+winl+',status=no,toolbar=no,scrollbars=1,resizable=yes'
	win = window.open(mypage, myname, winprops)
	if (parseInt(navigator.appVersion) >= 4) { win.window.focus(); }
}

function de(e){
	var d="punchestown";
        var p=".com";
        document.write("<a href='mailto:"+ e +"@"+ d + p +"'>"+ e +"@"+ d + p +"</a>");
}

// ]]>