{"id":11272,"date":"2023-06-09T11:56:21","date_gmt":"2023-06-09T11:56:21","guid":{"rendered":"https:\/\/www.visitanddo.com\/?page_id=11272"},"modified":"2025-07-14T13:29:52","modified_gmt":"2025-07-14T13:29:52","slug":"legacy-agradecimiento","status":"publish","type":"page","link":"https:\/\/www.visitanddo.com\/legacy-agradecimiento\/","title":{"rendered":"legacy-agradecimiento"},"content":{"rendered":"<div class=\"product\"><div class=\"product\">\n<div style=\"height:56px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n    <!-- TuriTop Event snippet for Purchase URL conversion page version 1.9 -->\n    <script>\n\n    function turitop_booking_system_thank_page() {}\n\n    turitop_booking_system_thank_page.prototype.init = function(){\n\n        \/* ############################################\n        ####      Parameter from google ads     ####\n        ############################################ *\/\n\n        this.send_to = []; this.send_to.push( ' ' );\n        \/* ############################################ *\/\n\n        \/* ############################################ *\/\n\n        \/* ############################################\n        ####      Parameter from google analytics 4    ####\n        ############################################ *\/\n    this.ga4 = ' ';\n    \/* ############################################ *\/\n\n    \/* ############################################\n       ####      Parameter from google tag manager    ####\n       ############################################ *\/\n    this.gtm = 'GTM-N9ZQZ3W';\n    \/* ############################################ *\/\n\n        this.current_url = window.location.search;\n        this.current_url_params = new URLSearchParams( this.current_url );\n\n        \/* ############################################\n            ####      Parameter from facebook ads     ####\n            ############################################ *\/\n    this.fbpixel = '2775274226114153';\n        if (typeof this.fbpixel === 'undefined' || typeof this.fbpixel === null || 0 === this.fbpixel.length){\n                this.fbpixel = this.current_url_params.get( 'fbpixel' );\n            }\n\n        this.sPageURL = decodeURIComponent( window.location.search.substring( 1 ) );\n        this.currency = this.current_url_params.get( 'currency' );\n        this.base_url = this.current_url_params.get( 'd' );\n        this.lang = this.current_url_params.get( 'lang' );\n        this.csid = this.current_url_params.get( 'csid' );\n        this.company_name = this.current_url_params.get( 'company_name' );\n        this.product_short_id = this.current_url_params.get( 'product_short_id' );\n        this.product_name = this.current_url_params.get( 'product_name' );\n        this.shopping_cart_id = this.current_url_params.get( 'shopping_cart_id' );\n        this.multiclient_hash = this.current_url_params.get( 'multiclient_hash' );\n        this.client_name = this.current_url_params.get( 'client_name' );\n        this.client_email = this.current_url_params.get( 'client_email' );\n        this.client_names = this.current_url_params.get( 'client_name[]' );\n        this.client_emails = this.current_url_params.get( 'client_email[]' );\n        this.buyer_email = this.current_url_params.get( 'buyer_email' );\n        this.payment_link = this.current_url_params.get( 'payment_link' );\n        this.totals = 0;\n        this.transaction_id = '';\n\n        this.tickets = [];\n\n        this.events();\n\n    };\n\n    turitop_booking_system_thank_page.prototype.events = function(){\n\n        this.get_totals();\n\n        this.get_transaction_id();\n\n        if ( this.payment_link == null || this.payment_link != 1 ){\n\n            if ( this.send_to || 0 != this.send_to || typeof this.send_to != 'undefined' ){\n                this.send_purchase_event_to_google_ads();\n            }\n\n            if ( this.fbpixel || 0 != this.fbpixel || typeof this.fbpixel != 'undefined' ){\n                this.send_purchase_event_to_facebook_ads();\n            }\n\n            if ( this.ga4 || 0 != this.ga4.length || typeof this.ga4 != 'undefined' && 0 == this.gtm.length ){\n                this.send_purchase_event_to_google_analytics_4();\n            }\n\n            if ( this.gtm || 0 != this.gtm.length || typeof this.gtm != 'undefined' && 0 == this.ga4.length ){\n                this.send_purchase_event_to_google_tag_manager();\n            }\n        }\n    };\n\n\n    turitop_booking_system_thank_page.prototype.getUrlParameter = function( sParam ){\n\n        var array =[]\n        var sURLVariables = this.sPageURL.split('&');\n        for ( var i = 0; i < sURLVariables.length; i++ ) {\n            var sParameterName = sURLVariables[ i ].split( '=' );\n            if ( sParameterName[ 0 ] == sParam ) {\n                array.push( sParameterName[ 1 ] );\n            }\n        }\n        return array;\n\n    };\n\n    turitop_booking_system_thank_page.prototype.get_totals = function(){\n\n        var total = this.getUrlParameter( 'total[]' );\n        if ( ! total || 0 === total.length || typeof total == 'undefined' ){\n\n        this.total = this.current_url_params.get( 'total' );\n\n        }\n        else{\n\n            var out = parseFloat( 0 );\n            for ( var i in total ) {\n                    out = out + parseFloat( total[i] );\n                }\n            this.total = out;\n        }\n\n    };\n\n    turitop_booking_system_thank_page.prototype.get_transaction_id = function(){\n\n        var booking_id = this.getUrlParameter( 'booking_id[]' );\n        if ( ! booking_id || 0 === booking_id.length || typeof booking_id == 'undefined' ){\n\n          this.transaction_id = this.current_url_params.get( 'booking_id' );\n\n          var ticket = {\n            booking_id: this.transaction_id,\n            url: this.base_url + this.current_url_params.get( 'link' ),\n            price: this.total\n          }\n          this.tickets.push( ticket );\n\n        }\n        else{\n\n            var link = this.getUrlParameter( 'link[]' );\n            var price = this.getUrlParameter( 'price[]' );\n            var out = '';\n            var cart_id = '';\n            var multiclient = '';\n            if ( this.shopping_cart_id != null ){\n                cart_id = this.shopping_cart_id;\n                multiclient = '';\n            }\n             if ( this.multiclient_hash != null ){\n                multiclient = this.multiclient_hash;\n                cart_id = '';\n            }\n\n            for ( var i in booking_id ) {\n\n                var ticket = {\n                    booking_id: booking_id[ i ],\n                    url: this.base_url + link[ i ],\n                    price: price[ i ],\n                    cart_id: cart_id,\n                    multiclient: multiclient\n                }\n                this.tickets.push( ticket );\n\n                out += \"-Booking-\" + booking_id[ i ];\n                this.buttons = [];\n            }\n            this.transaction_id = out;\n\n        }\n\n    };\n\n\n    turitop_booking_system_thank_page.prototype.send_purchase_event_to_google_ads = function(){\n\n        if (typeof gtag === 'function') {\n            for ( var i in this.send_to ) {\n\n                gtag('event', 'conversion', {\n                    'send_to': this.send_to[ i ],\n                    'value': this.total,\n                    'currency': this.currency,\n                    'transaction_id': this.transaction_id\n                });\n\n            }\n        }\n    };\n\n    turitop_booking_system_thank_page.prototype.send_purchase_event_to_facebook_ads = function(){\n\n        if (typeof fbq === 'function') {\n\n            if ( typeof this.fbpixel != 'undefined' || this.fbpixel ){\n                fbq( 'track', 'Purchase', {\n                    'value': this.total,\n                    'currency': this.currency\n                  });\n            }\n        }\n    };\n\n    turitop_booking_system_thank_page.prototype.send_purchase_event_to_google_analytics_4 = function(){\n\n        if (typeof gtag === 'function') {\n\n            if ( 0 != this.ga4.length ){\n                var tid = '';\n\n                for ( var i in this.tickets ) {\n                    if ( this.tickets[i].cart_id != '' ){\n                        tid = this.tickets[i].cart_id;\n                    }\n                    if ( this.tickets[i].multiclient != '' ){\n                        tid = this.tickets[i].multiclient;\n                    }\n                    if ( typeof this.tickets[i].multiclient == 'undefined' || typeof this.tickets[i].cart_id == 'undefined' ) {\n                        tid = this.tickets[i].booking_id;\n                    }\n                    gtag('event', 'purchase', {\n                        'transaction_id': tid, \/\/IF shopping cart, shopping cart id, IF multiclient, multiclient hash, ELSE, booking number\n                        'currency': this.currency, \/\/ local currency code\n                        'value': this.total, \/\/Valor total\n                        'items': [\n                            { \/\/one item per product bought\n                            'item_id': this.product_short_id, \/\/Short_id product\n                            'item_name': this.product_name, \/\/Nombre del producto en idioma original\n                            'item_brand': this.csid + '-' + this.company_name, \/\/company short ID + nombre empresa. En caso de reventa, usar datos del proveedor\n                            'item_category': this.lang, \/\/Language\n                            'price': this.tickets[i].price, \/\/Valor pagado por producto comprado, ejemplo 9.99\n                            'currency': this.currency, \/\/ local currency code product\n                            'quantity': 1 \/\/Aqu\u00ed siempre se pone 1, aunque se hayan comprado varios tipos de tickets\n                            }\n                        ]\n                    });\n                }\n            }\n        }\n    };\n\n    turitop_booking_system_thank_page.prototype.send_purchase_event_to_google_tag_manager = function(){\n\n        if ( 0 != this.gtm.length ){\n            var tid = '';\n\n            for ( var i in this.tickets ) {\n                if ( this.tickets[i].cart_id != '' ){\n                    tid = this.tickets[i].cart_id;\n                }\n                if ( this.tickets[i].multiclient != '' ){\n                    tid = this.tickets[i].multiclient;\n                }\n                if ( typeof this.tickets[i].multiclient == 'undefined' || typeof this.tickets[i].cart_id == 'undefined' ) {\n                    tid = this.tickets[i].booking_id;\n                }\n                dataLayer = window.dataLayer || [];\n                window.dataLayer.push({\n                event: \"purchase\",\n                ecommerce: {\n                    transaction_id: tid, \/\/IF shopping cart, shopping cart id, IF multiclient, multiclient hash, ELSE, booking number\n                    currency: this.currency, \/\/ local currency code\n                    value: this.total, \/\/Valor total\n                    items: [\n                        { \/\/one item per product bought\n                        item_id: this.product_short_id, \/\/Short_id product\n                        item_name: this.product_name, \/\/Nombre del producto en idioma original\n                        item_brand: this.csid + '-' + this.company_name, \/\/company short ID + nombre empresa. En caso de reventa, usar datos del proveedor\n                        item_category: this.lang, \/\/Language\n                        price: this.tickets[i].price, \/\/Valor pagado por producto comprado, ejemplo 9.99\n                        currency: this.currency, \/\/ local currency code product\n                        quantity: 1 \/\/Aqu\u00ed siempre se pone 1, aunque se hayan comprado varios tipos de tickets\n                        }\n                    ]\n                }\n                });\n            }\n        }\n};\n\nturitop_booking_system_thank_page.prototype.fill_tickets = function(){\n\n    for ( var i in this.tickets ) {\n\n    var html = '<div class=\"turitop_thank_you_page_ticket\">';\n\n        html = html + '<div class=\"turitop_thank_you_page_ticket_booking_id\">';\n            html = html + this.tickets[i].booking_id;\n        html = html + '<\/div>';\n\n        html = html + '<div class=\"turitop_thank_you_page_ticket_url\">';\n            html = html + '<a href=\"' + this.tickets[i].url + '\" target=\"_blank\"> <button>Descargar \/ Imprimir<\/button> <\/a>';       html = html + '<\/div>';\n\n   html = html + '<\/div>';\n\n   document.getElementById( \"turitop_thank_you_page_tickets\" ).insertAdjacentHTML( \"afterbegin\", html );\n\n   }\n\n   if ( this.tickets.length > 1 )\n       var tickets_title =\"Sus n\u00fameros de referencia:\";\nelse\nvar tickets_title =\"Su n\u00famero de referencia:\";\n    var name = '';\n    var email = '';\n\n    if ( this.client_name != null ) {\n        var name = this.client_name;\n    }\n    if ( this.client_names != null ) {\n        var name = this.client_names;\n    }\n    if ( this.client_email != null) {\n        var email = this.client_email;\n    }\n    if ( this.client_emails != null) {\n        var email = this.client_emails;\n    }\nhtml_booking_data = '<div class=\"turitop_thank_you_page_tickets_booking_data\">Datos reserva<\/div>';\nif ( name != '' ) {\n    html_booking_data =  html_booking_data + '<div class=\"turitop_thank_you_page_tickets_booking_data\">' +\"Nombre\"+ \": \" + name + '<\/div>';\n}\nif ( email != '' ) {\nhtml_booking_data = html_booking_data + '<div class=\"turitop_thank_you_page_tickets_booking_data\">' +\"Email\"+ \": \" + email +'<\/div>';\n}\nif ( this.buyer_email != null  ) {\n    html_booking_data = html_booking_data + '<div class=\"turitop_thank_you_page_tickets_booking_data\">' +\"Email del comprador\"+ \": \" + this.buyer_email +'<\/div>';\n}\nif ( this.product_name != null ) {\n    html_booking_data = html_booking_data + '<div class=\"turitop_thank_you_page_tickets_booking_data\">' +\"Producto reservado\"+ \": \" + this.product_name +'<\/div>';\n}\nif ( this.total != null ) {\n    html_booking_data = html_booking_data + '<div class=\"turitop_thank_you_page_tickets_booking_data\">' +\"Total\"+ \": \" + this.total + \" \" + this.currency +'<\/div>';\n      }\n      document.getElementById( \"turitop_thank_you_page_tickets\" ).insertAdjacentHTML( \"afterbegin\", '<div class=\"turitop_thank_you_page_tickets_title\">' + tickets_title + '<\/div>' );\n      document.getElementById( \"turitop_thank_you_page_tickets\" ).insertAdjacentHTML( \"afterend\", html_booking_data );\n  };\n    var turitop_booking_system_thank_page_instance = new turitop_booking_system_thank_page();\n    turitop_booking_system_thank_page_instance.init();\n\n    <\/script>\n\n    <style>\n\n    .turitop_thank_you_page_wrap{\n        display: block;\n        width: 100%;\n        text-align: center;\n    }\n\n    .turitop_thank_you_page_wrap .turitop_thank_you_page_red_dark{\n        color: #900;\n    }\n\n    .turitop_thank_you_page_tickets{\n        margin: 20px 0;\n    }\n\n    .turitop_thank_you_page_tickets_title .turitop_thank_you_page_tickets_booking_data{\n        font-size: bold;\n        margin-bottom: 8px;\n    }\n\n    .turitop_thank_you_page_wrap .turitop_thank_you_page_ticket{\n        display: inline-flex;\n        justify-content: center;\n        align-items: center;\n        margin-bottom: 5px;\n        flex-wrap: wrap;\n    }\n\n    .turitop_thank_you_page_wrap .turitop_thank_you_page_ticket_booking_id{\n        display: inline-block;\n        background: #f2f2f2;\n        border: 1px solid #b3b3b3;\n        border-radius: 2px;\n        font-size: 34px;\n        font-weight: 700;\n        padding: 10px 15px;\n        margin: 5px;\n    }\n\n    .turitop_thank_you_page_wrap .turitop_thank_you_page_ticket_url{\n        margin: 5px;\n    }\n\n    <\/style>\n\n    <div class=\"turitop_thank_you_page_wrap\">\n\n        <div class=\"turitop_thank_you_page_title\">\u00a1Gracias!    <\/div>\n\n    <div id=\"turitop_thank_you_page_tickets\" class=\"turitop_thank_you_page_tickets\">\n\n\n\n    <\/div>\n\n    <div class=\"turitop_thank_you_page_message\">\n\n        <p>Importante: Para obtener la confirmaci\u00f3n y los detalles de la reserva, compruebe su correo electr\u00f3nico, incluida la carpeta SPAM. Puede tardar unos minutos en llegar.        <\/p>\n\n        <p class=\"turitop_thank_you_page_red_dark\">Si no recibe ning\u00fan correo electr\u00f3nico de confirmaci\u00f3n en menos de 30 minutos, por favor, p\u00f3ngase en contacto con nosotros. No se ha podido confirmar la reserva.            <\/p>\n\n        <\/div>\n\n    <\/div>\n\n    <script>\n\n    turitop_booking_system_thank_page_instance.fill_tickets();\n\n    <\/script>\n\n\n\n<style>\nheader.page-header{\ndisplay:none;}\n\n\n<\/style>\n\n\n\n<div style=\"height:56px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n<\/div><\/div>","protected":false},"excerpt":{"rendered":"<p>\u00a1Gracias! Importante: Para obtener la confirmaci\u00f3n y los detalles de la reserva, compruebe su correo electr\u00f3nico, incluida la carpeta SPAM. Puede tardar unos minutos en llegar. Si no recibe ning\u00fan correo electr\u00f3nico de confirmaci\u00f3n en menos de 30 minutos, por favor, p\u00f3ngase en contacto con nosotros. No se ha podido confirmar la reserva.<\/p>\n","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"_acf_changed":false,"_eb_attr":"","hub_intro":"","hub_icono":"","hub_h2_recogida":"","hub_recogida":"","hub_h2_extra":"","hub_extra":"","footnotes":""},"class_list":["post-11272","page","type-page","status-publish","hentry"],"acf":[],"_links":{"self":[{"href":"https:\/\/www.visitanddo.com\/de\/wp-json\/wp\/v2\/pages\/11272","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.visitanddo.com\/de\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/www.visitanddo.com\/de\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/www.visitanddo.com\/de\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.visitanddo.com\/de\/wp-json\/wp\/v2\/comments?post=11272"}],"version-history":[{"count":9,"href":"https:\/\/www.visitanddo.com\/de\/wp-json\/wp\/v2\/pages\/11272\/revisions"}],"predecessor-version":[{"id":24099,"href":"https:\/\/www.visitanddo.com\/de\/wp-json\/wp\/v2\/pages\/11272\/revisions\/24099"}],"wp:attachment":[{"href":"https:\/\/www.visitanddo.com\/de\/wp-json\/wp\/v2\/media?parent=11272"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}