// VERSION ESPAÑOL

//logo

document.write('<div id="logo" style="position:absolute; width:329px; height:46px; z-index:1; left: 7; top: 4"><img src="/baselogo.gif"></div>');


//imagen al lado del logo
//document.write('<div id="logo" style="position:absolute; width:329px; height:46px; z-index:1; left: 313; top: -1"><img src="nube.gif"></div>');


//barra de menu

document.write('<div id="barra" style="position:absolute; width:747px; height:3px; z-index:2; left: 9px; top: 65px"><img src="/basebarra.jpg"></div>');

document.write('<div id="barra2" style="position:absolute; width:747px; height:3px; z-index:2; left: 9px; top: 79px"><img src="/basebarra.jpg"></div>');



//opciones de menu



document.write('<div id="barra_opciones" style="position:absolute; width:724px; height:14px; z-index:6; left: 27px; top: 76px"> ');

document.write('  <table width="100%" border="0">');

document.write('    <tr> ');

document.write('      <td width="8%"> ');

document.write('        <div align="center"><a href="/index.php"><font face=verdana size="-2"><b>Home</b></font></a></div>');

document.write('      </td>');

document.write('      <td width="15%"> ');

document.write('        <div align="center"><a href="/artesanos.php"><font face=verdana size="-2"><b>Artesanos</b></font></a></div>');

document.write('      </td>');

document.write('      <td width="10%"> ');

document.write('        <div align="center"><a href="/cursos.htm"><font face=verdana size="-2"><b>Cursos</b></font></a></div>');

document.write('	  </td>');

document.write('      <td width="10%"> ');

document.write('        <div align="center"><a href="/ferias.php"><font face=verdana size="-2"><b>Ferias</b></font></a></div>');

document.write('      </td>');

document.write('      <td width="11%"> ');

document.write('        <div align="center"><a href="/noticias.php"><font face=verdana size="-2"><b>Noticias</b></font></a></div>');

document.write('      </td>');

document.write('      <td width="13%"> ');

document.write('        <div align="center"><a href="/productos.php"><font face=verdana size="-2"><b>Productos</b></font></a></div>');

document.write('      </td>');

document.write('      <td width="12%"> ');

document.write('        <div align="center"><a href="/rubros.php"><font face=verdana size="-2"><b>Rubros</b></font></a></div>');

document.write('      </td>');

document.write('      <td width="13%"> ');

document.write('        <div align="center"><a href="/e-sow/e-sowartesanos.php"><font face=verdana size="-2"><b>e-SOW</b></font></a></div>');

document.write('      </td>');

document.write('    </tr>');

document.write('  </table>');

document.write('</div>');





//sobre

document.write('<div id="sobre" style="position:absolute; width:48px; height:43px; z-index:7; left: 715px; top: 7px"><a href="/registracion.php" onMouseOver="fMostrarOcultar(\'mnMensajes\',\'\',\'show\')" onMouseOut="fMostrarOcultar(\'mnMensajes\',\'\',\'hide\')"><img src="/baseIco48.gif" width="45" height="52" border="0" alt="Mensajes - Sugerencias"></a></div>');



//ingles - español

//document.write('<div id="sobre" style="position:absolute; width:48px; height:43px; z-index:7; left: 640px; top: 23px"><img src="/base_es_light.gif" border="0"</div>');

//document.write('<div id="sobre" style="position:absolute; width:48px; height:43px; z-index:7; left: 639px; top: 37px"><a href="/OOO" onMouseOver="fMostrarOcultar(\'mnMensajes\',\'\',\'show\')" onMouseOut="fMostrarOcultar(\'mnMensajes\',\'\',\'hide\')"><img src="/base_en_dark.gif" border="0" alt="English version"></a></div>');



//titulo y fecha

document.write('<div id="tituloyhora" class="favoinicio" style="position:absolute; width:299px; height:32px; z-index:3; left: 380px; top: 8px"> ');

document.write('  <table width="100%" border="0" cellpadding="0" cellspacing="0" height="42"> ');

document.write('    <tr>  ');

document.write('      <td colspan="2">  ');

document.write('        <div align="center"><img src="/elsitiodelosartesanos.gif"></div> ');

document.write('      </td> ');

document.write('    </tr> ');

document.write('    <tr>  ');

document.write('      <td colspan="2">  ');

document.write('        <div align="center"><font face=verdana size=-2>');

		<!--

		var now = new Date()

		var dia = now.getDay()

		var mes = now.getMonth()

		var anio= now.getFullYear()

		var fecha

		//El día de la semana

		if(dia==0){

		 fecha="Domingo ";

		}else if(dia==1){

		 fecha="Lunes ";

		}else if(dia==2){

		 fecha="Martes ";

		}else if(dia==3){

		 fecha="Miércoles ";

		}else if(dia==4){

		 fecha="Jueves ";

		}else if(dia==5){

		 fecha="Viernes ";

		}else{

		 fecha="Sábado ";

		}

		fecha = fecha + now.getDate() + " de "

		//El nombre del mes

		if(mes==0){

		 fecha=fecha + "enero"

		}else if(mes==1){

		 fecha=fecha + "febrero"

		}else if(mes==2){

		 fecha=fecha + "marzo"

		}else if(mes==3){

		 fecha=fecha + "abril"

		}else if(mes==4){

		 fecha=fecha + "mayo"

		}else if(mes==5){

		 fecha=fecha + "junio"

		}else if(mes==6){

		 fecha=fecha + "julio"

		}else if(mes==7){

		 fecha=fecha + "agosto"

		}else if(mes==8){

		 fecha=fecha + "septiembre"

		}else if(mes==9){

		 fecha=fecha + "octubre"

		}else if(mes==10){

		 fecha=fecha + "noviembre"

		}else{

		 fecha=fecha + "diciembre"

		}

		fecha = fecha + " de " + anio

		//-->

document.write(fecha);

document.write('<br>');

document.write("Buenos Aires - Argentina");

document.write('</font></div> ');

document.write('      </td> ');

document.write('    </tr> ');

document.write('  </table> ');

document.write('</div> ');



//favoritos y pagina de inicio


document.write('<div id="barra2_opciones" class="favoinicio" style="position:absolute; width:724px; height:14px; z-index:6; left: 27px; top: 62px"> ');

document.write('  <table width="100%" border="0">');

document.write('    <tr> ');

document.write('      <td width="11%"> ');

document.write('        <div align="center"><font face=verdana size=-2><a href="#" onClick="window.external.AddFavorite(\'http://www.artesanosenlaweb.com\', \'Artesanos en la Web\')">Agregar a favoritos</a></font></div> ');

document.write('      </td>');



document.write('      <td width="11%"> ');

document.write('        <div align="center"><font face=verdana size=-2><a href="/buscador.php">Buscador</a></font></div> ');

document.write('      </td>');



document.write('      <td width="12%"> ');

document.write('        <div align="center"><font face=verdana size=-2><a href="/calendario.htm">Calendario</a></font></div> ');

document.write('      </td>');



document.write('      <td width="12%"> ');

document.write('        <div align="center"><font face=verdana size=-2><a href="/eventos.php">Eventos</a></font></div> ');

document.write('      </td>');



document.write('      <td width="12%"> ');

document.write('        <div align="center"><font face=verdana size=-2><a href="#" onClick="this.style.behavior=\'url(#default#homepage)\';this.setHomePage(\'http://www.artesanosenlaweb.com\');">Tu página de inicio</a></font></div> ');

document.write('      </td>');

document.write('    </tr>');

document.write('  </table>');

document.write('</div>');





//funcion para chequear email

function checkEmail(emailStr) {

   if (emailStr.length == 0)

     return true;

   var emailPat=/^(.+)@(.+)$/;

   var specialChars="()<>@,;:\".[]";

   var validChars="[^s" + specialChars + "]";

   var quotedUser="(\"[^\"]*\")";

   var ipDomainPat=/^(d{1,3})[.](d{1,3})[.](d{1,3})[.](d{1,3})$/;

   var atom=validChars + '+';

   var word="(" + atom + "|" + quotedUser + ")";

   var userPat=new RegExp("^" + word + "(." + word + ")*$");

   var domainPat=new RegExp("^" + atom + "(." + atom + ")*$");

   var matchArray=emailStr.match(emailPat);



   if (matchArray == null)

      return false;



   var user=matchArray[1];

   var domain=matchArray[2];



   if (user.match(userPat) == null)

      return false;



   var IPArray = domain.match(ipDomainPat);

   if (IPArray != null) {

      for (var i = 1; i <= 4; i++) {

         if (IPArray[i] > 255)

         	return false;

   		}



   return true;

	 }



   var domainArray=domain.match(domainPat);

   if (domainArray == null)

      return false;



   var atomPat=new RegExp(atom,"g");

   var domArr=domain.match(atomPat);

   var len=domArr.length;



   if (domArr[domArr.length-1].length < 2 || domArr[domArr.length-1].length > 3)

      return false;



   if (len < 2)

      return false;



   return true;

}

