<!--//
	function onlineCinema(dest) {
    <!--//
		// the URL of the experience site
		var cinemaURL = "http://www.experience-hollandamerica.com/experience/index.php";
		
		// If we're not linking to a specific page, open the home page
		if (dest == null) {
		    onlineCinemaWindow = window.open(cinemaURL,'popupWindow','scrollbars=auto,resizable=yes,width=740,height=520,left=50,top=10');
		} else {
		    onlineCinemaWindow = window.open(dest,'popupWindow','scrollbars=auto,resizable=yes,width=740,height=520,left=50,top=10');
		}
	
	    if(onlineCinemaWindow.opener == null)
	    {
	        onlineCinemaWindow.opener = window;
	    }
	    onlineCinemaWindow.focus();
	//-->
	}

function resizeWindow(w,h) {
 if (parseInt(navigator.appVersion)>3) {
   if (navigator.appName=="Netscape") {
    top.outerWidth=w;
    top.outerHeight=h;
   }
   else top.resizeTo(w,h);
 }
}

function HALLink(dest) {
	// the URL of the experience site
	var defaultURL = "http://www.experience-hollandamerica.com/";
	
	// If we're not linking to a specific page, open the home page
	if (dest == '' || dest == null) {
		if (opener != null && !opener.closed) {
			opener.location.href = defaultURL;
			if (window.focus) { opener.focus()}
		} else {
		    halWindow = window.open(defaultURL);
			if (window.focus) { halWindow.focus()}
		    opener = halWindow;
		}
	} else {
// this is currently failing in firefox if the user has closed the parent window. need to research more...
// && (!opener.closed && opener.location)
		if (opener != null && !opener.closed) {
			opener.location.href = dest;
			if (window.focus) { opener.focus()}
		} else {
		    halWindow = window.open(dest);
			if (window.focus) { halWindow.focus()}
		    opener = halWindow;
		}
	}
}
function resSpecialistPopup()
{
	window.open( 'https://crm.hollandamerica.com/broadbaseema/ha3051/cpa.jsp?srce=cpb', "resSpecPopup", "toolbar=yes,width=545,height=550,resizable=yes,scrollbars=yes" );
}

function emailSignUp()
{
  //window.open( 'https://halsurvey2.vcrm2.com/broadbaseema/ha3067/survey.jsp', "emailSignUp", "toolbar=yes,width=545,height=550,resizable=yes,scrollbars=yes" );

//  window.open( 'https://crm.hollandamerica.com/broadbaseema/ha4018/survey.jsp', "emailSignUp", "toolbar=yes,width=545,height=380,resizable=yes,scrollbars=yes" );
  window.open( 'https://crm.hollandamerica.com/broadbaseema/ha5032/survey.jsp', "emailSignUp", "toolbar=yes,width=460,height=590,resizable=yes,scrollbars=yes" );
}
function popDestPano(vtid){
var settings='width=371,height=354,top=5,left=5,scrollbars=no,location=no,directories=no,status=no,menubar=no,toolbar=no,resizable=yes'
// var win=window.open('http://display.maxvr.com/hal/viewer.asp?id=' + vtid,'vrxviewer',settings);
var win=window.open('http://delivery.vrxstudios.com/hal/destination/vrxviewer.asp?content=dest&amp;id=' + vtid,'vrxviewer',settings);
win.focus();
}

function popDestPano2(vtid){
var settings='width=371,height=354,top=5,left=5,scrollbars=no,location=no,directories=no,status=no,menubar=no,toolbar=no,resizable=yes'
// var win=window.open('http://display.maxvr.com/hal/viewer.asp?id=' + vtid,'vrxviewer',settings);
var win=window.open('http://www.360travelguide.net/hal/ipix/idisp.asp?ipixnum=' + vtid,'vrxviewer',settings);
win.focus();
}


function popShipPano(vtid){
var settings='width=371,height=354,top=5,left=5,scrollbars=no,location=no,directories=no,status=no,menubar=no,toolbar=no,resizable=yes'
// var win=window.open('http://display.maxvr.com/hal/viewer.asp?id=' + vtid,'vrxviewer',settings);
var win=window.open('http://delivery.vrxstudios.com/hal/destination/vrxviewer.asp?content=ship&amp;id=' + vtid,'vrxviewer',settings);
win.focus();
}


function showShipPano(vtid){
	var ifrm = null;
	if (document.getElementById) { 
		ifrm = document.getElementById('vrxviewer');
	} else if (document.all) {
		ifrm =document.all.vrxviewer;
	}
	var vrxURL = "http://delivery.vrxstudios.com/hal/destination/vrxviewer.asp?content=ship&amp;id=" + vtid ;
//	var vrxURL = "http://display.maxvr.com/hal/viewer.asp?id=" + vtid ;
	ifrm.src = vrxURL;
	ifrm.style.display = "block"; 
}

function showDestPano(vtid){
	var ifrm = null;
	if (document.getElementById) { 
		ifrm = document.getElementById('vrxviewer');
	} else if (document.all) {
		ifrm =document.all.vrxviewer;
	}
	var vrxURL = "http://delivery.vrxstudios.com/hal/destination/vrxviewer.asp?content=dest&amp;id=" + vtid ;
//	var vrxURL = "http://display.maxvr.com/hal/viewer.asp?id=" + vtid ;
	ifrm.src = vrxURL;
	ifrm.style.display = "block"; 
}

function showDestPano_360travelguide(vtid){
	var ifrm = null;
	if (document.getElementById) { 
		ifrm = document.getElementById('vrxviewer');
	} else if (document.all) {
		ifrm =document.all.vrxviewer;
	}
	var vrxURL = "http://www.360travelguide.net/hal/ipix/idisp.asp?ipixnum=" + vtid ;
//	var vrxURL = "http://display.maxvr.com/hal/viewer.asp?id=" + vtid ;
	ifrm.src = vrxURL;
	ifrm.style.display = "block"; 
}

function showDestPano_maxvrtravelguide(vtid){
	var ifrm = null;
	if (document.getElementById) { 
		ifrm = document.getElementById('vrxviewer');
	} else if (document.all) {
		ifrm =document.all.vrxviewer;
	}
//	var vrxURL = "http://www.360travelguide.net/hal/ipix/idisp.asp?ipixnum=" + vtid ;
	var vrxURL = "http://display.maxvr.com/hal/viewer.asp?id=" + vtid ;
	ifrm.src = vrxURL;
	ifrm.style.display = "block"; 
}


//POPUP FUNCTION FOR GENERAL SIZE
function openPopup(dest,width,height)
{
    if ( "undefined" == typeof width )
    {
        width = 495;
    }

    if ( "undefined" == typeof height )
    {
        height = 525;
    }

    thePopup = window.open(dest,'nxtbook','location=yes,scrollbars=yes,resizable=yes,width=' + width + ',height=' + height + ',left=50,top=10');

    if(thePopup.opener == null)
    {
        thePopup.opener = window;
    }
	try
	{		
		thePopup.focus();
		
	}
	catch (e)
	{
		// nothing to do.
	}
}
	//-->
