function PopWindow() {
	window.open('photos.cfm?Label=#URL.Path#','photos','width=640,height=400,menubar=no,scrollbars=yes,toolbar=no,location=no,directories=no,resizable=no'); 
}

function popMap() {
	window.open('/link.cfm?address=#urlencodedformat("http://sites.truenorthmap.com/alabama/map.jsp?Label=" & URL.Path)#','map','width=665,height=600,menubar=no,scrollbars=yes,toolbar=no,location=no,directories=no,resizable=no');
}

function popUp(myType, myID){
	var myServer = window.location.hostname;

	if(myType == "Lodging"){
		myType = "accommodations";
	}else if(myType == "Attraction"){
		myType = "attractions";
	}

	day = new Date();
	id = day.getTime();
	var myWin = window.open("/travel-tools/vacation/vacationplanner.cfm?itemType="+myType+"&itemID="+myID, id ,'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=800,height=495,left = 10,top = 10');
}

function tagSearch(tag) {
	term = tag.innerHTML;
	document.getElementById("search").value = tag.innerHTML;
	document.getElementById("form1").submit();
	
}

function flashBox(elementID) {
	document.getElementById('activeImage').src = imageArray[elementID];
	document.getElementById('activeImageCaption').innerHTML = imageCaptionArray[elementID];
	document.getElementById('activeImageLink').onclick = function() {photoBox(elementID); return false;} ;
}

function photoBox(elementID) {
	if (document.getElementById(elementID).click) {
		document.getElementById(elementID).click();
	} else {
		var evObj = document.createEvent('MouseEvents');
		evObj.initMouseEvent( 'click', true, true, window, 1, 12, 345, 7, 220, false, false, true, false, 0, null );
		document.getElementById(elementID).dispatchEvent(evObj);
	}
}

function activateTab(elementID) {
	if (document.getElementById(elementID).click) {
		document.getElementById(elementID).click();
	} else {
		var evObj = document.createEvent('MouseEvents');
		evObj.initMouseEvent( 'click', true, true, window, 1, 12, 345, 7, 220, false, false, true, false, 0, null );
		document.getElementById(elementID).dispatchEvent(evObj);
	}
}
