/***********************************************
* Scripts for fincalaraya.com
***********************************************/

//cancel-window, pdf-window
function openwindow (url) {
 fenster = window.open(url, "fenster1", "width=464,height=270,left=180,top=100,status=yes,scrollbars=yes,resizable=yes");
 fenster.focus();
}

//Browserweiche: BG-attachment fixed oder scroll
//historia.htm =1
function check1 (){
function checkBrowserName(name){
var agent = navigator.userAgent.toLowerCase();
if (agent.indexOf(name.toLowerCase())>-1) {
return true;
}
return false;
}

if (checkBrowserName('MSIE')){window.location.href='es/historia2.htm';}
else{window.location.href='es/historia.htm';}
}

//hotel.htm =2
function check2 (){
function checkBrowserName(name){
var agent = navigator.userAgent.toLowerCase();
if (agent.indexOf(name.toLowerCase())>-1) {
return true;
}
return false;
}

if (checkBrowserName('MSIE')){window.location.href='es/hotelb.htm';}
else{window.location.href='es/hotel.htm';}
}

//habit.htm =3
function check3 (){
function checkBrowserName(name){
var agent = navigator.userAgent.toLowerCase();
if (agent.indexOf(name.toLowerCase())>-1) {
return true;
}
return false;
}

if (checkBrowserName('MSIE')){window.location.href='es/habitb.htm';}
else{window.location.href='es/habit.htm';}
}

//comedor.htm =4
function check4 (){
function checkBrowserName(name){
var agent = navigator.userAgent.toLowerCase();
if (agent.indexOf(name.toLowerCase())>-1) {
return true;
}
return false;
}

if (checkBrowserName('MSIE')){window.location.href='es/comedorb.htm';}
else{window.location.href='es/comedor.htm';}
}

//ubic.htm =5
function check5 (){
function checkBrowserName(name){
var agent = navigator.userAgent.toLowerCase();
if (agent.indexOf(name.toLowerCase())>-1) {
return true;
}
return false;
}

if (checkBrowserName('MSIE')){window.location.href='es/ubicb.htm';}
else{window.location.href='es/ubic.htm';}
}

//
function checkbuform() {

function checkBrowserName(name){
var agent = navigator.userAgent.toLowerCase();
if (agent.indexOf(name.toLowerCase())>-1) {
return true;
}
return false;
}

if(checkBrowserName('MSIE')){
url="es/reservar_1b.htm";
parent.location.href=url;
}

else if(checkBrowserName('opera')){
url="es/reservar_1.htm";
parent.location.href=url;
}

else if(checkBrowserName('safari')){
url="es/reservar_1.htm";
parent.location.href=url;
}

else if(checkBrowserName('firefox')){
url="es/reservar_1.htm";
parent.location.href=url;
}

else (url="es/reservar_1.htm");
parent.location.href=url;

}