function initializar_mail() {
$(function() {
  $('.error').hide();
  $('input.text-input').css({backgroundColor:"#FFFFFF"});
  $('input.text-input').focus(function(){
    $(this).css({backgroundColor:"#DBF9FA"});
  });
  $('input.text-input').blur(function(){
    $(this).css({backgroundColor:"#FFFFFF"});
  });
  $('textarea.text-input').css({backgroundColor:"#FFFFFF"});
  $('textarea.text-input').focus(function(){
    $(this).css({backgroundColor:"#DBF9FA"});
  });
  $('textarea.text-input').blur(function(){
    $(this).css({backgroundColor:"#FFFFFF"});
  });

  $(".button").click(function() {
    $('.error').hide();
		//valido nombre
	  var nombre = $("input#nombre").val();
		if (nombre == "") {
      $("label#nombre_error").show().fadeIn(200);
      $("input#nombre").focus();
      return false;
    }
		//valido mail
	var email = $("input#email").val();
	if (email == "") {
      		$("label#email_error").show();
		  	$("input#email").focus();
			return false;
    }
	//valida el asunto
	var asunto = $("input#asunto").val();
	if (asunto == "") {
      $("label#asunto_error").show();
      $("input#asunto").focus();
      return false;
    }
	//mensaje
	var mensaje = $("textarea#mensaje").val();
	if (mensaje == "") {
      $("textarea#mensaje").focus();
      return false;
    }
		
		var dataString = 'nombre='+ nombre + '&email=' + email + '&asunto=' + asunto + '&mensaje=' + mensaje;
		
	  $.ajax({
      type: "POST",
      url: "modulos/contactos/php/enviar_mail.php",
      data: dataString,
      success: function() {
        $('#contacto').html("<div id='mensaje' class='center'></div>");
        $('#mensaje').html("<p><strong>Consulta Enviada Correctamente!</strong></p>")
        .append("<p>Muchas Gracias. Le responderemos a la brevedad.</p>")
        .hide()
        .fadeIn(1500);/*, function() {
          $('#message').append("<img id='checkmark' src='images/check.png' />");
        });*/
      }
     });
    return false;
	});
});
/*runOnLoad(function(){
  $("input#nombre").select().focus();
});*/
}
