function click()
	 {if (event.button==2)
		{alert ('Copyright © Derechos Reservados')}
 	 }
	 document.onmousedown=click

function popHelp(wmsg,wimage)
	{
	  PopIt(wmsg,wimage);
	}

function AbreVentana(wVentana,nh,nw) {
	var wid_doc = wVentana;
    window.open(wid_doc, "_blank", "toolbar=no,menubar=no,directories=no,status=no,resizable=no,location=no,scrollbars=no,height="+nh+",width="+nw+",screenX=1,screenY=1")
	}


function PopIt(msg,wimage)
	{
		  var s1 = 
		    "<TITLE>Photo Window</TITLE>" +
		    "<BODY BGCOLOR=white><TABLE BORDER=0><TR>" +
		        "<TD WIDTH='100%' HEIGHT='100%' VALIGN=TOP ALIGN=LEFT>"+
		        "<IMG SRC="+wimage+">"

		  var s2 = 
		    "</TD></TR>"+
			"<TR><TD VALIGN=MIDDLE ALIGN=LEFT>"+
			"<P><FONT FACE='MS Sans Serif' SIZE='2' COLOR='#295981'>"+
			msg+"</FONT></P></TD></TR>"  

		  var s3 =   
		    "<TR><TD VALIGN=TOP ALIGN=RIGHT>"+
		    "<FORM><INPUT TYPE='BUTTON' VALUE='Cerrar'" +
		                   "onClick='self.close()'>"  +
		    "</FORM></TD></TR></TABLE></BODY>"
		 
		  popup = window.open("","popDialog","height=440,width=530,scrollbars=1,resizable=yes")
		  popup.document.write(s1+s2+s3)
		  popup.document.close()
	}

function favorito()
{
	var txt_fav =
	"	<div id=link1 align=center style=\"position:relative;height:19px;overflow:off; width:140px;\">"+
	"		<a class=link1 href=\"javascript:window.external.AddFavorite('http://www.kre-at.com','Kre-At Diseño y Publicidad')\">"+
	"		<b><font size=\"2\" face=\"Verdana, Arial, Helvetica, sans-serif\">"+
	"		&nbsp;Añadir a favoritos</b></font></a></div>"
	document.write(txt_fav);
}

function fecha()
	{
		var now = new Date();
		var days = new Array('Domingo','Lunes','Martes','Miercoles','Jueves','Viernes','Sabado');
		var months = new Array('Enero','Febrero','Marzo','Abril','Mayo','Junio','Julio','Agosto','Setiembre','Octubre','Noviembre','Diciembre');
		var date = ((now.getDate()<10) ? "0" : "")+ now.getDate();
			today = " &nbsp; " + days[now.getDay()] + ", " + date + " de " + 
		   	          months[now.getMonth()] + " de " +
	           	    (fourdigits(now.getYear())) ;
						
		document.write("" +today+ ".");
		}					

function fourdigits(number)	{
		return (number < 1000) ? number + 1900 : number;
		}

function high(which2) 
		{ 
			theobject=which2; 
			highlighting=setInterval("highlightit(theobject)",70); 
		} 

function low(which2) 
		{ 
			clearInterval(highlighting); 
			which2.filters.alpha.opacity=70; 
		} 

function highlightit(cur2) 
		{ 
			if(cur2.filters.alpha.opacity<100) 
				cur2.filters.alpha.opacity+=5 
			else if(window.highlighting) 
				clearInterval(highlighting) 
		} 

function mOvr(src,clrOver) {
		if (!src.contains(event.fromElement)) {
			src.style.cursor = 'hand';
			ColorFondo = src.bgColor;
			src.bgColor = clrOver;
		}
	}

function mOut(src) {
		if (!src.contains(event.toElement)) {
			src.style.cursor = 'default';
			src.bgColor = ColorFondo;
		}
	}

function mClk(src) {
		if(event.srcElement.tagName=='TD') {
			src.children.tags('A')[0].click();
		}
	}


function verificar()
{
  if ( (f.nombre.value=="") || (f.apellidos.value=="") || (f.emailcontrata.value=="") || (f.asunto.value=="") || (f.consulta.value=="") )
    {
      alert ('Por favor, ingrese la información en los campos marcados con asterisco\nGracias');
      return; 
    } 
  else if(f.emailcontrata.value.indexOf("@")==-1 || f.emailcontrata.value.indexOf(".")==-1) 
  {
    alert("Su direccion de correo electronica es incorrecta, verifiquela por favor");
  }
  else
  {
  f.action="http://kre-at.com/php/contacto.php";
  f.submit();
  }
}

