SurveyVista – Styles

/* Modal Backdrop */ .modal { display: none; position: fixed; z-index: 10001; /* Z-index of a modal */ left: 0; top: 0; width: 100%; height: 100%; overflow: hidden; background-color: rgba(0, 0, 0, 0.6); } /* Modal Box Centered */ .modal-content…Continue reading

SurveyVista – Script to Control Modal

window.addEventListener(“load”, () => { setTimeout(() => { const iFrame = document.getElementById(“surveyFrame”); // Load survey in background AFTER page load if (iFrame && iFrame.dataset.src) { iFrame.src = iFrame.dataset.src; } }, 0); // Show modal after X amount of seconds setTimeout(() =>…Continue reading

Determinar altura del header

jQuery(window).on(‘elementor/frontend/init’, function() { // Elementor tiene su propio evento de carga de componentes jQuery(window).on(‘load’, function() { function updateHeaderHeight() { // Seleccionamos el header const $header = jQuery(‘.elementor-location-header .elementor-sticky’); const $body = jQuery(‘body’); if ($header.length) { let headerHeight = 0; if…Continue reading

Corrección de widgets tipo “slides.default”

(function(jQuery) { ‘use strict’; const fixSlidesClases = function() { if (elementorFrontend && elementorFrontend.hooks) { // Filtramos específicamente por el widget de slides elementorFrontend.hooks.addAction(‘frontend/element_ready/slides.default’, function($scope) { // Buscamos el wrapper que debería tener la clase de swiper // En versiones recientes…Continue reading

Body on Scroll (copy)

;(function ($) { $(window).scroll(function() { var scroll = $(window).scrollTop(); if (scroll >= 5) { $(“body”).addClass(“scroll-500”); $(“.tm-header”).removeClass(“uk-blend-difference”); } else { $(“body”).removeClass(“scroll-500”); $(“.tm-header”).addClass(“uk-blend-difference”); } }); })(jQuery);Continue reading

Create Estimated 5* Google Reviews Count Shortcodes & Action Hooks for Rich Showcase for Google Reviews Plugin

if (!function_exists(‘rd_rr_table_exists’)) { function rd_rr_table_exists(string $table): bool { global $wpdb; $found = $wpdb->get_var($wpdb->prepare(“SHOW TABLES LIKE %s”, $table)); return !empty($found); } } if (!function_exists(‘rd_rr_round_down_step’)) { function rd_rr_round_down_step(int $value, int $step): int { if ($step prefix . ‘grp_google_stats’; if (!rd_rr_table_exists($stats_table)) { return…Continue reading

Registro de Widget Personalizado – Lista Dinámica ACF

/** * Registro de Widget Personalizado – Lista Dinámica ACF * Este widget extrae datos de campos repetidores de ACF y permite un diseño profesional. */ add_action( ‘elementor/widgets/register’, function( $widgets_manager ) { class Mi_Widget_Lista_Dinamica extends \Elementor\Widget_Base { /** * Configuración…Continue reading

ACF option field shortcode

function acf_option_field_shortcode( $atts ) { // Definimos los atributos por defecto (solo necesitamos ‘field’) $atts = shortcode_atts( array( ‘field’ => ”, // Clave del campo a obtener ), $atts, ‘opcion_acf’ ); // Aseguramos que se ha proporcionado un nombre de…Continue reading