// Opens a new browser window with the specified URL
function openWindow(url) 
{ 
  var newWin = window.open(url, 'newWin'); 
}

function popupGeneric(PopName){
	var features = "menubar=no,scrollbars=yes,resizable=yes,toolbar=yes,width=600,height=550,left=50,top=50";
	if (popupGeneric.arguments.length == 2) {
		features = popupGeneric.arguments[1];
	}
	genericPop = window.open (PopName, 'winPop', features);
	genericPop.focus();
}

function openPhotoTourWindow(tourName) {
  var whichTourPath = "/phototours/phototour2.aspx?whichtour=" + tourName
  photoTourWindow=open(whichTourPath, "Photo", "width=615,height=510,left=50,top=50,menubar=no,toolbar=no,location=no,status=no,scrollbars=yes,resizable=yes");
  photoTourWindow.focus();
}
function openPhotoTourWindowSF(tourName) {
  var whichTourPath = "http://www.ilsc.ca/phototours-sf/phototour2.aspx?whichtour=" + tourName
  photoTourWindow=open(whichTourPath, "Photo", "width=615,height=510,left=50,top=50,menubar=no,toolbar=no,location=no,status=no,scrollbars=yes,resizable=yes");
  photoTourWindow.focus();
}
function openTorontoVirtualTourWindow(tourName) {
  var whichTourPath = "/quicktime/virtualtour.aspx?whichtour=" + tourName
  virtualTourWindow=open(whichTourPath, "Tour", "width=625,height=470,left=50,top=50,menubar=no,toolbar=no,location=no,status=no,scrollbars=yes,resizable=yes");
  virtualTourWindow.focus();
}
function openTorontoVirtualTourWindowHiRes(tourName) {
  var whichTourPath = "/quicktime/virtualtour.aspx?whichtour=" + tourName + "&res=high"
  virtualTourWindowHR=open(whichTourPath, "TourHR", "width=850,height=720,left=150,top=150,menubar=no,toolbar=no,location=no,status=no,scrollbars=yes,resizable=yes");
  virtualTourWindowHR.focus();
}
function openFreeESLWindow() {
   newWindow=window.open('http://ilsc.free-english.com','freeesl', 'toolbar=no,status=no,menubar=no,scrollbars=yes,resizable=yes,directories=no,location=no,width=780,height=575,left=15,top=15')
  // newWindow=window.open('/freeesltempnotice.html','freeesl', 'toolbar=no,status=no,menubar=no,scrollbars=yes,resizable=yes,directories=no,location=no,width=600,height=275,left=55,top=55')
}


/* Prints contents of window */
function printWindow(){
	if (window.print)
		window.print();
}
   


/* Close Popup and open a link in parent window */

function linkMain(popLink) {
	if(window.opener){
		(window.opener.location.href=popLink);
		window.close();
	}
	else {
		location.href = popLink;
	}
}
