$(function(){
		/*$('#contactAt').contactable({
	 		recipient: 'contacto@solucionesim.net',
	 		subject: 'Contacto desde el Sitio Web'
	 	});

		$('div#headerBt').click(
		function() {
			$('#headerContent').animate({"marginTop": "-=60px"}, "slow");
			$(this).animate({"marginTop": "-=60px"}, "slow").animate({"marginTop": "+=5px"}, "fast"); 
			
			$('#TotalBodyId').animate({"marginTop": "-=60px"}, "slow");
			$('#TotalBodyId').css({backgroundPosition: "0 0"});
			
		});
		$('div#footerBt').click(function() {
			$('#footerContent').animate({"marginBottom": "-=45px"}, "slow");
			$(this).animate({"marginBottom": "-=45px"}, "slow").animate({"marginBottom": "+=5px"}, "fast"); 
		});
		*/
		$("#btn_suscribe_boletin").click(function(){
			$("label.error").hide(); 
			$("input#nombre_usuario").removeClass("focus_error");  
			$("input#correo_usuario").removeClass("focus_error");  
			$("input#correo_usuario_2").removeClass("focus_error");  
			
			var nombre_usuario = $("input#nombre_usuario").val();  
			var correo_usuario = $("input#correo_usuario").val();  
			var correo_usuario_2 = $("input#correo_usuario_2").val();  
			
			if (nombre_usuario == "") 
			{
				$("label.error").show(); 
				$("input#nombre_usuario").focus().addClass("focus_error");   
				return false;  
			} 
			if (correo_usuario == "") 
			{
				$("label.error").show(); 
				$("input#correo_usuario").focus().addClass("focus_error");   
				return false;  
			} 
			if (correo_usuario_2 == "") 
			{
				$("label.error").show(); 
				$("input#correo_usuario_2").focus().addClass("focus_error");   
				return false;  
			}
			if (correo_usuario != correo_usuario_2) 
			{
				$("label.error").show(); 
				$("input#correo_usuario").focus().addClass("focus_error");   
				return false;  
			}
		});
		
	$(".registro_dominio").click(function() 
	{
		$("label.error").hide();
		var nombre = $("input#nombre").val();
		var telefono = $("input#telefono").val();
		var email = $("input#email").val();
		var dominio = $("input#dominio").val();
		
		if (nombre == "") 
		{
			$("label.error").show(); 
			$("input#nombre").focus().addClass("focus_error");   
			return false;  
		}
		if (telefono == "") 
		{
			$("label.error").show(); 
			$("input#telefono").focus().addClass("focus_error");  
			 return false;  
		}  
		if (email == "") 
		{  
			$("label.error").show(); 
			$("input#email").focus().addClass("focus_error");  
			 return false;  
		} 
		if (dominio == "") 
		{  
			$("label.error").show(); 
			$("input#dominio").focus().addClass("focus_error");  
			 return false;  
		}
	});

	$('#dialogo_mapa').dialog({
		autoOpen: false,
		width: 560,
		height: 580,
		modal: true,
		buttons: {
			"Cerrar": function() { 
				$(this).dialog("close"); 
			}
		}
	});
	$('.dialog_mapa').click(function(){
		$('#dialogo_mapa').dialog('open');
		return false;
	});

	$('#dialogo_portafolio_diprocssa').dialog({
		autoOpen: false,
		width: 600,
		height: 480,
		modal: true,
		buttons: {
			"Cerrar": function() { 
				$(this).dialog("close"); 
			}
		}
	});

	$('#dialogo_portafolio_mgyg').dialog({
		autoOpen: false,
		width: 600,
		height: 550,
		modal: true,
		buttons: {
			"Cerrar": function() {
				$(this).dialog("close"); 
			}
		}
	});
	
	$('#dialogo_portafolio_ral').dialog({
		autoOpen: false,
		width: 600,
		height: 580,
		modal: true,
		buttons: {
			"Cerrar": function() {
				$(this).dialog("close"); 
			}
		}
	});
	
	$('#dialogo_portafolio_mundo_can').dialog({
		autoOpen: false,
		width: 600,
		height: 580,
		modal: true,
		buttons: {
			"Cerrar": function() {
				$(this).dialog("close"); 
			}
		}
	});

	$('#dialogo_portafolio_grupo_origenes').dialog({
		autoOpen: false,
		width: 600,
		height: 590,
		modal: true,
		buttons: {
			"Cerrar": function() {
				$(this).dialog("close"); 
			}
		}
	});

	$('#dialogo_portafolio_amantoli').dialog({
		autoOpen: false,
		width: 600,
		height: 590,
		modal: true,
		buttons: {
			"Cerrar": function() {
				$(this).dialog("close"); 
			}
		}
	});
	
	$('#dialogo_portafolio_da_vinci').dialog({
		autoOpen: false,
		width: 600,
		height: 590,
		modal: true,
		buttons: {
			"Cerrar": function() {
				$(this).dialog("close"); 
			}
		}
	});
	
	$('#dialogo_portafolio_ventaspnl').dialog({
		autoOpen: false,
		width: 600,
		height: 590,
		modal: true,
		buttons: {
			"Cerrar": function() {
				$(this).dialog("close"); 
			}
		}
	});
	
	$('#dialogo_portafolio_banquetes').dialog({
		autoOpen: false,
		width: 600,
		height: 590,
		modal: true,
		buttons: {
			"Cerrar": function() {
				$(this).dialog("close"); 
			}
		}
	});
	
	$('#dialogo_portafolio_map').dialog({
		autoOpen: false,
		width: 600,
		height: 430,
		modal: true,
		buttons: {
			"Cerrar": function() {
				$(this).dialog("close"); 
			}
		}
	});
	
	$('#dialogo_portafolio_triton').dialog({
		autoOpen: false,
		width: 600,
		height: 590,
		modal: true,
		buttons: {
			"Cerrar": function() {
				$(this).dialog("close"); 
			}
		}
	});
	
	$('#dialogo_portafolio_acupuntura').dialog({
		autoOpen: false,
		width: 600,
		height: 590,
		modal: true,
		buttons: {
			"Cerrar": function() {
				$(this).dialog("close"); 
			}
		}
	});
	
	$('#dialogo_portafolio_kampe').dialog({
		autoOpen: false,
		width: 600,
		height: 590,
		modal: true,
		buttons: {
			"Cerrar": function() {
				$(this).dialog("close"); 
			}
		}
	});
	
	$('#dialogo_portafolio_fiestas').dialog({
		autoOpen: false,
		width: 600,
		height: 590,
		modal: true,
		buttons: {
			"Cerrar": function() {
				$(this).dialog("close"); 
			}
		}
	});
	
	$('#dialogo_twitter').dialog({
		autoOpen: false,
		width: 600,
		height: 550,
		modal: true,
		buttons: {
			"Cerrar": function() {
				$(this).dialog("close"); 
			}
		}
	});
	
	$('#dialogo_facebook').dialog({
		autoOpen: false,
		width: 600,
		height: 550,
		modal: true,
		buttons: {
			"Cerrar": function() {
				$(this).dialog("close"); 
			}
		}
	});
	
	$('#dialogo_portafolio_cuetzalan').dialog({
		autoOpen: false,
		width: 600,
		height: 590,
		modal: true,
		buttons: {
			"Cerrar": function() {
				$(this).dialog("close"); 
			}
		}
	});
	
});


function muestra_dialog(dialogo_muestra)
{
		$('#' + dialogo_muestra).dialog('open');
		return false;

}
