var parentOpen="";var parentClose="";$(document).ready(function(){var size=$(".listNinguno ul li").size();$(".listNinguno ul li").each(function(index){if(index>=size/2){$(this).appendTo("#Column2 ul");}});resizeHeader();$(document).ready(function(){vph=$(window).height();vpw=$(window).width();$(".youtube:not(.socialIcon)").colorbox({iframe:true,maxWidth:840,maxHeight:475,width:vpw,height:vph,fixed:true});});if($(".page_producto .pd_descripcion").text()=='.')$(".productos_descripcion").hide();});$(window).resize(function(){resizeHeader();$(".page_resumen .divTienda #comments").attr("placeholder","Por favor, indica la hora y el día de recogida en caso de que vengas a recogerlo.");});function resizeHeader(){$("header.art-header.myHeader").height(Math.min($(".ws_images ul li:first-child").height(),600));$("header.art-header.myHeader").css({"overflow":"hidden"});} $(document).ready(function(){$(".desktop .btn_add_carrito").click(function(){$("#miniCartDiv").show();});});var forceCapaFija=false;$(document).ready(function(){var altura=$("nav li").height();$('.art-nav>div>ul:not(.art-menu-iconos)').prepend('
  • logo
  • ');$('.logoCapaFija img').css("height",altura-12);$('.logoCapaFija img').css("width","auto");$('.logoCapaFija img').css("max-height","89%");});$(document).bind('scroll',onScroll);function onScroll(){if($(document).height()>$(window).height()+$("nav.art-nav.desktop-nav").height()){if(!forceCapaFija&&$(window).scrollTop()<$("nav.art-nav.desktop-nav").height()){$(".desktop .art-nav").removeClass('capaFija');$("html").removeClass('capaFijaHtml');}else{$(".desktop .art-nav").addClass('capaFija');$("html").addClass('capaFijaHtml');}}} $(document).bind("touchmove",function(e){onScrollMobile();});function onScrollMobile(){if($(document).height()>$('body').height()+$("nav.art-nav.desktop-nav").height()){if(!forceCapaFija&&$('body').scrollTop()<$("nav.art-nav.desktop-nav").height()){$(".responsive .art-nav").removeClass('capaFija');}else{$(".responsive .art-nav").addClass('capaFija');}}} $(document).ready(function(){$("#searchsubmit").click(function(){if($("#doo_s").val()!='') location.href="buscar-productos-"+$("#doo_s").val().replaceAll(" ","+");});var timer=null;var texto='';$("#doo_s").keyup(function(){if(texto!=$("#doo_s").val()){clearTimeout(timer);timer=setTimeout(doStuff,100);texto=$("#doo_s").val();}});});function doStuff(){if($("#doo_s").val()!=''){jQuery.ajax({contentType:"application/x-www-form-urlencoded",type:"POST",url:"https://www.factinet.com/setAjaxVars.php",data:"action=searchProductos&letra=ez&identificador=decasadeana&Id=458&MAIN=https://www.factinet.com/&search="+$("#doo_s").val()+"&all=",success:function(datos){if(datos!=''){$(".search-results").html(datos);$(".search-results").show();jQuery("img").error(function(){event.preventDefault();jQuery(this).attr("title",jQuery(this).attr("src"));jQuery(this).attr("src","/cacheimg?zc=2&w=400&h=400&src=images/no-picture.png");jQuery(this).css({"width":"100%","opacity":"0.2"});});$(".search-results .h").click(function(){$(".search-results").hide();});}else{$(".search-results").hide();}}});}} function pulsaTecla(e){tecla=(document.all)?e.keyCode:e.which;if(tecla==13){if($("#doo_s").val()!='') location.href="buscar-productos-"+$("#doo_s").val().replaceAll(" ","+");}} $(document).ready(function(){$(".search-btn").click(function(){$(".divDoofinder").fadeToggle();$(function(){$(".search-form #doo_s").focus();});});});jQuery(document).ready(function(){$(".art-menu-logo").html('');jQuery(".art-menu-logo").click(function(){location.href="/";});});$(document).ready(function(){$(".desktop #miniCart > a").attr("href","#");$("#miniCart").click(function(){$('.desktop #miniCartDiv').fadeToggle();$('li#miniCart').toggleClass("cartRightDiv");});});function reCaptchaOnFocus(){var head=document.getElementsByTagName('head')[0] var script=document.createElement('script') script.type='text/javascript';script.src='https://www.google.com/recaptcha/api.js?render=6LecO4MUAAAAACd76VNXkHVzwH6qdWnldjEg44Vz' head.appendChild(script);script.onload=()=>{grecaptcha.ready(function(){grecaptcha.execute("6LecO4MUAAAAACd76VNXkHVzwH6qdWnldjEg44Vz",{action:"action_name"}).then(function(token){jQuery('[name="g-recaptcha-response"]').val(token);});});};document.getElementById('Nombre').removeEventListener('focus',reCaptchaOnFocus);document.getElementById('Email').removeEventListener('focus',reCaptchaOnFocus);} jQuery(document).ready(function(){document.getElementById('Nombre').addEventListener('focus',reCaptchaOnFocus,false);document.getElementById('Email').addEventListener('focus',reCaptchaOnFocus,false);});jQuery(document).ready(function(){jQuery(".clkNormas").colorbox({maxHeight:"700px",height:"90%",maxWidth:"700px",width:"90%",fixed:true});jQuery(".clkAviso").colorbox({maxHeight:"700px",height:"90%",maxWidth:"700px",width:"90%",fixed:true});jQuery(".rgpd_1nivel").mouseover(function(){jQuery(this).css("height","initial");jQuery(this).css("overflow","unset");});jQuery(".rgpd_1nivel").mouseout(function(){jQuery(this).css("height","80px");jQuery(this).css("overflow","hidden");});});jQuery("#contactPage").ready(function(){if(0){jQuery("#contactPage").submit(function(event){event.preventDefault();});} jQuery.validator.setDefaults({submitHandler:function(){if(0){jQuery.ajax({contentType:"application/x-www-form-urlencoded",type:"POST",url:"contacto.inc&clean=1",data:jQuery("#contactPage").serialize()+"&plantillaEmail=",success:function(datos){jQuery("#contactPage .divForm").text("");jQuery(".resultContacto").html(datos);;}});}else{Submit();}}});jQuery("#contactPage").validate({rules:{Nombre:{required:true},Apellidos:{required:true},Asunto:{required:true},Mensaje:{required:true},Email:{required:true,email:true},Telefono:{required:false,phone:true},Acepto:{required:true}}});var rgpdHeight=jQuery("#contactPage .rgpd_1nivel").css("height");jQuery("#contactPage .rgpd_1nivel").mouseover(function(){jQuery(this).css("height","initial");jQuery(this).css("overflow","unset");});jQuery("#contactPage .rgpd_1nivel").mouseout(function(){jQuery(this).css("height",rgpdHeight);jQuery(this).css("overflow","hidden");});});if(window.history.replaceState){window.history.replaceState(null,null,window.location.href);} var lat='40.864917';var lon='-3.612925';var map;function createHomeLatLngMap(lat,lng){map=$("#map_canvas").goMap({zoom:15,maptype:'ROADMAP',mapTypeControl:true,places:"off",latitude:lat,longitude:lng});} $(document).ready(function(){createHomeLatLngMap(lat,lon);});jQuery(document).ready(function(){jQuery('.wallDirectorio').jaliswall({item:'.headerDirectorio'});});function setMarker(titulo,descripcion,lat,lon,icon,w,h){var icon={url:icon,scaledSize:new google.maps.Size(w,h),};$.goMap.createMarker({title:titulo,html:{content:descripcion},latitude:lat,longitude:lon,icon:icon,zIndex:1});} $(document).ready(function(){setMarker('De Casa de Ana Cotos','

    \'icono\'De Casa de Ana Cotos

    c/ del Puerto de Despeñaperros. Local 2 Cotos de Monterrey Madrid
    https://decasadeana.es/
    ',40.790208,-3.602796,'images/map_icons/supermarket.png',30,34.6875);setMarker('De Casa de Ana La Cabrera','

    \'icono\'De Casa de Ana La Cabrera

    Av. de la Cabrera, 35, 28751 La Cabrera, Madrid La Cabrera Madrid
    https://decasadeana.es/
    ',40.864858,-3.612962,'images/map_icons/supermarket.png',30,34.6875);});$(document).ready(function(){});$(document).ready(function(){$.goMap.fitBounds();$('.art-button').click(function(e){e.preventDefault();showLoader();setTimeout('location.href = "'+$(this).attr("href")+'"',3000);});});function hideLoader(){$(".se-pre-con").fadeOut("slow");} function showLoader(){$(".se-pre-con").fadeIn("slow");} function validar(){if(jQuery("#formNewsletter").valid()){addUserNewsletter();}} jQuery(document).ready(function(){jQuery("#btn_enviar").click(function(event){event.preventDefault();validar();});jQuery("#formNewsletter").validate({rules:{email:{required:true,email:true},politica:{required:true},nombre:{required:true},tipo_usuario:{required:true}}});var rgpdHeight=jQuery("#div_mini_newsletter .rgpd_1nivel").css("height");jQuery("#div_mini_newsletter .rgpd_1nivel").mouseover(function(){jQuery(this).css("height","initial");jQuery(this).css("overflow","unset");});jQuery("#div_mini_newsletter .rgpd_1nivel").mouseout(function(){jQuery(this).css("height",rgpdHeight);jQuery(this).css("overflow","hidden");});});function addUserNewsletter(){jQuery.ajax({contentType:"application/x-www-form-urlencoded",type:"POST",url:"addUserNewsletter&clean=1",data:jQuery("#formNewsletter").serialize(),success:function(datos){if(datos.status=='success'){Swal.fire({title:'Registro correcto!',text:datos.message,icon:'error',confirmButtonText:'Ok',onClose:()=>{jQuery("#div_mini_newsletter").html(datos.message);}})}else{if(datos.status=='error'){Swal.fire({title:'Error!',text:datos.error_msg,icon:'error',confirmButtonText:'Ok',onClose:()=>{jQuery("#div_mini_newsletter").html(datos.error_msg);}})}}},error:function(datos){}});} $(document).ready(function(){window.setInterval(kenBurns,500);function kenBurns(){$("#full-width-slider .rsSlide:hidden img").removeClass("fx");$("#full-width-slider .rsSlide:visible img").addClass("fx");}});window.dataLayer=window.dataLayer||[];function gtag(){dataLayer.push(arguments);} gtag('js',new Date());gtag('config','UA-3938643-34');jQuery("#div_descripcion div,#div_descripcion p,#div_descripcion span,#div_descripcion a").not(".button").css({'color':'','font-size':'','text-indent':'','background-color':'transparent'});jQuery("#div_descripcion img").css({'max-width':'700px'});jQuery(document).ready(function(){jQuery("img:not(.pixelCode)").error(function(){event.preventDefault();jQuery(this).attr("title",jQuery(this).attr("src"));jQuery(this).attr("src","/cacheimg?zc=2&w=400&h=400&src=images/no-picture.png");jQuery(this).css({"width":"100%","opacity":"0.2"});});jQuery(".vlightbox1:not(.noColorbox)").colorbox({rel:'vlightbox1',maxWidth:'100%',maxHeight:'100%',slideshow:true,slideshowSpeed:600,slideshowStart:"Continuar",slideshowStop:"Parar",current:"{current} de {total}"});jQuery('a[href$=".jpg"], a[href$=".jpeg"], a[href$=".gif"], a[href$=".png"], a[href$=".JPG"], a[href$=".JPEG"], a[href$=".GIF"], a[href$=".PNG"]').not(".noColorbox").colorbox({maxWidth:'100%',maxHeight:'100%',slideshow:true,slideshowSpeed:6000});jQuery("a[href^='http']").not("[href*='"+location.host+"']").not("[notarget*='1']").attr('target','_blank');if($(".readmore").length){$('').insertAfter($(".readmore"));$('.readmore').toggleClass("readmore__content__close");$('.readmore').css("height",$('.readmore').data("height"));jQuery(".readmore__toggle").click(function(){$(this).prev().toggleClass("readmore__content__close");if($(this).prev().hasClass("readmore__content__close")){$(this).text("Leer más...");$(this).prev().css("height",$('.readmore').data("height"));}else{$(this).text("Leer menos...");$(this).prev().css("height","initial");}});}});jQuery(document).ready(function(){jQuery('#shareme, .shareme').sharrre({share:{facebook:true,twitter:false,googlePlus:false,pinterest:false},buttons:{googlePlus:{url:'http://decasadeana.es/contacto',size:'medium',lang:'es-ES',annotation:''},facebook:{url:'http://decasadeana.es/contacto',action:'like',layout:'button',width:'',send:'false',faces:'false',colorscheme:'',font:'',lang:'es_ES'},twitter:{url:'http://decasadeana.es/contacto',count:'horizontal',via:'factinet_es',hashtags:'',related:'',lang:'es'},pinterest:{url:'http://decasadeana.es/contacto',media:'https://www.factinet.com/uploads/grupos/e53f2cf1d0f6b8a68056b5b187a25f5e_cacheimg.jpg',description:'Comida sana y casera para llevar. Encarga tu pedido semanal o llévate platos sueltos para comer en casa.',layout:'horizontal'}},enableHover:false,enableCounter:false,enableTracking:true});$('a[href*="#"]:not([href="#"])').click(function(event){if(typeof($($.attr(this,'href')).offset())!='undefined'){event.preventDefault();$('html, body').animate({scrollTop:$($.attr(this,'href')).offset().top-($(".capaFija").is(":visible")*-100)-100},500);}});});