// JavaScript Document
function agregar_favoritos(cadena_url){
   if ((navigator.appName=="Microsoft Internet Explorer") && 
         (parseInt(navigator.appVersion)>=4)) {
      var url="http://" + cadena_url; 
      var titulo=cadena_url;
      window.external.AddFavorite(url,titulo);
   } else { 
      if(navigator.appName == "Netscape") 
         alert("Presione Crtl+D para agregar este sitio en sus Bookmarks"); 
   }
} 

function validar_correo(){
pas_mail = document.recibir_ofertas.email.value;

var error="";
 if(pas_mail == "" || pas_mail=="Escriba su email..." ){
   error += "Introduzca su Email.\n";
 }else{
   if ((document.recibir_ofertas.email.value.indexOf ('@', 0) == -1)||(document.recibir_ofertas.email.value.length < 5)) {
     error += "Formato de email no válido.\n"
   }
 }

 if(error== ""){
   document.recibir_ofertas.submit();
 }else{
   alert(error);
 }

}

function dar_formato_java_buscador(cadena){
     
	 cadena = cadena.replace(/\s/g,"-");
	 cadena = cadena.replace(/ñ/g,"n");
	 cadena = cadena.replace(/á/g,"a");
	 cadena = cadena.replace(/é/g,"e");
	 cadena = cadena.replace(/í/g,"i");
	 cadena = cadena.replace(/ó/g,"o");
	 cadena = cadena.replace(/ú/g,"u");
	 cadena = cadena.replace(/Á/g,"A");
	 cadena = cadena.replace(/É/g,"E");
	 cadena = cadena.replace(/Í/g,"I"); 
	 cadena = cadena.replace(/Ó/g,"O");
	 cadena = cadena.replace(/Ú/g,"U");
	 cadena = cadena.replace(/\*/g,"");
	 cadena = cadena.replace(/\"/g,"");
	 cadena = cadena.replace(/,/g,"");
	 cadena = cadena.replace(/\./g,"");
	 cadena = cadena.replace(/\(/g,"");
	 cadena = cadena.replace(/\)/g,""); 
	 cadena = cadena.replace(/ä/g,"a");
	 cadena = cadena.replace(/ë/g,"e");
	 cadena = cadena.replace(/ï/g,"i");
	 cadena = cadena.replace(/ö/g,"o");
	 cadena = cadena.replace(/ü/g,"u");
	 cadena = cadena.replace(/Ä/g,"A");
	 cadena = cadena.replace(/Ë/g,"E");
	 cadena = cadena.replace(/Ï/g,"I"); 
	 cadena = cadena.replace(/Ö/g,"O");
	 cadena = cadena.replace(/Ü/g,"U");
	 cadena = cadena.replace(/\//g,"");
	
	 return cadena;
	}

/*
Cross browser Marquee script- © Dynamic Drive (www.dynamicdrive.com)
For full source code, 100's more DHTML scripts, and Terms Of Use, visit http://www.dynamicdrive.com
Credit MUST stay intact
*/

//Specify the marquee's width (in pixels)
var marqueewidth="695px"
//Specify the marquee's height
var marqueeheight="54px"
//Specify the marquee's marquee speed (larger is faster 1-10)
var marqueespeed=2
//configure background color:
var marqueebgcolor="#ffffff"
//Pause marquee onMousever (0=no. 1=yes)?
var pauseit=1

//Specify the marquee's content (don't delete <nobr> tag)
//Keep all content on ONE line, and backslash any single quotations (ie: that\'s great):

var marqueecontent='<nobr>&nbsp;&nbsp;&nbsp;<img src="/img/mayorista1.jpg" width="78" height="52" alt="Alquiler de Coches con Budget" />        &nbsp;&nbsp;&nbsp;<img src="/img/mayoristas2.jpg" width="82" height="52" alt="Alquiler de Coches con Sol-Mar"/>&nbsp;&nbsp;&nbsp;<img src="/img/mayoristas3.jpg" width="83" height="54" alt="Alquiler de Coches con Atesa"/>&nbsp;&nbsp;&nbsp;<img src="/img/mayoristas4.jpg" width="78" height="53"  alt="Alquiler de Coches con Hertz"/>&nbsp;&nbsp;&nbsp;<img src="/img/mayoristas5.jpg" width="78" height="53"  alt="Alquiler de Coches con Avis"/>   &nbsp;&nbsp;&nbsp;<img src="/img/mayoristas6.jpg" width="85" height="53" alt="Alquiler de Coches con Alamo"/>&nbsp;&nbsp;&nbsp;<img src="/img/mayoristas7.jpg" width="84" height="54" alt="Alquiler de Coches con Sixt"/>&nbsp;&nbsp;&nbsp;<img src="/img/mayoristas8.jpg" width="80" height="53" alt="Alquiler de Coches con Europcar"/>&nbsp;&nbsp;&nbsp;<img src="/img/mayorista1.jpg" width="78" height="52"  alt="Alquiler de Coches con Budget"/>      &nbsp;&nbsp;&nbsp;<img src="/img/mayoristas2.jpg" width="82" height="52"  alt="Alquiler de Coches con Sol-Mar"/>&nbsp;&nbsp;&nbsp;<img src="/img/mayoristas3.jpg" width="83" height="54"  alt="Alquiler de Coches con Atesa"/>&nbsp;&nbsp;&nbsp;<img src="/img/mayoristas4.jpg" width="78" height="53"  alt="Alquiler de Coches con Hertz"/>&nbsp;&nbsp;&nbsp;<img src="/img/mayoristas5.jpg" width="78" height="53"  alt="Alquiler de Coches con Avis"/>&nbsp;&nbsp;&nbsp;<img src="/img/mayoristas6.jpg" width="85" height="53"  alt="Alquiler de Coches con Alamo"/>&nbsp;&nbsp;&nbsp;&nbsp;<img src="/img/mayoristas7.jpg" width="84" height="54"  alt="Alquiler de Coches con Sixt"/>&nbsp;&nbsp;&nbsp;<img src="/img/mayoristas8.jpg" width="80" height="53"  alt="Alquiler de Coches con Europcar"/></nobr>';


////NO NEED TO EDIT BELOW THIS LINE////////////
marqueespeed=(document.all)? marqueespeed : Math.max(1, marqueespeed-1) //slow speed down by 1 for NS
var copyspeed=marqueespeed
var pausespeed=(pauseit==0)? copyspeed: 0
var iedom=document.all||document.getElementById
if (iedom)
document.write('<span id="temp" style="visibility:hidden;position:absolute;top:-100px;left:-9000px">'+marqueecontent+'</span>')
var actualwidth=''
var cross_marquee, ns_marquee

function populate(){
if (iedom){
cross_marquee=document.getElementById? document.getElementById("iemarquee") : document.all.iemarquee
cross_marquee.style.left=parseInt(marqueewidth)+8+"px"
cross_marquee.innerHTML=marqueecontent
actualwidth=document.all? temp.offsetWidth : document.getElementById("temp").offsetWidth
}
else if (document.layers){
ns_marquee=document.ns_marquee.document.ns_marquee2
ns_marquee.left=parseInt(marqueewidth)+8
ns_marquee.document.write(marqueecontent)
ns_marquee.document.close()
actualwidth=ns_marquee.document.width
}
lefttime=setInterval("scrollmarquee()",20)
}


function scrollmarquee(){
if (iedom){
if (parseInt(cross_marquee.style.left)>(actualwidth*(-1)+8))
cross_marquee.style.left=parseInt(cross_marquee.style.left)-copyspeed+"px"
else
cross_marquee.style.left=parseInt(marqueewidth)+8+"px"

}
else if (document.layers){
if (ns_marquee.left>(actualwidth*(-1)+8))
ns_marquee.left-=copyspeed
else
ns_marquee.left=parseInt(marqueewidth)+8
}
}


