// Popup window caller
var popUpBrazExpWin=0;
function popUpBrazExp(URLStr, left, top, width, height)
{
  if(popUpBrazExpWin)
  {
	if(!popUpBrazExpWin.closed) popUpBrazExpWin.close();
  }
  popUpBrazExpWin = open(URLStr, 'popUpBrazExpWin', 'toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=no,copyhistory=yes,width='+width+',height='+height+',left='+left+', top='+top+',screenX='+left+',screenY='+top+'');
}


// For offer button
function smartToOfferRedirect(theurl) {
	if (opener && window.name=="popUpHotelWin") { /* Current window is a popup, so redirect the main window (= parent) to offer section (window name is set in /products/detail/fbx_Settings.cfm) */
	/* if (opener && String(opener.location).indexOf('#CGI.SERVER_NAME#')>0) { */
		opener.window.location=theurl;
		opener.window.focus();
	}
	else { /* Redirect 'own' window to offer-section */
		window.location=theurl;
	}
}


// For hotel popup
var popUpHotelWin=0;
function popUpHotel(URLStr, left, top, width, height) {
  if(popUpHotelWin)
  {
	if(!popUpHotelWin.closed) popUpHotelWin.close();
  }
  popUpHotelWin = open(URLStr, 'popUpHotelWin', 'toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=no,copyhistory=yes,width='+width+',height='+height+',left='+left+', top='+top+',screenX='+left+',screenY='+top+'');
}



// Disable Right-click (works also in Firefox)
function right(e) {
  if (e && e.which && (e.which == 3 || e.which == 2)) return false;
  else if (window.event && (event.button == 2 || event.button == 3)) {
	nocontextmenu();
    return false;
  }
  return true;
}
function nocontextmenu() {
   //alert('Sorry! To avoid Internet pilfering this function has been diabled.');
   return false;
}
document.onmousedown=right;
if (window.captureEvents) window.captureEvents(Event.MOUSEDOWN);
window.onmousedown=right;
document.oncontextmenu = nocontextmenu;
document.onmousedown = right;
document.onmouseup = right;