{"id":3738,"date":"2026-06-18T13:25:51","date_gmt":"2026-06-18T11:25:51","guid":{"rendered":"https:\/\/meralunits.com\/bookings\/"},"modified":"2026-07-03T08:26:37","modified_gmt":"2026-07-03T06:26:37","slug":"bookings","status":"publish","type":"page","link":"https:\/\/meralunits.com\/en\/bookings\/","title":{"rendered":"Bookings"},"content":{"rendered":"\t\t<div data-elementor-type=\"wp-page\" data-elementor-id=\"3738\" class=\"elementor elementor-3738 elementor-3643\" data-elementor-post-type=\"page\">\n\t\t\t\t<div class=\"elementor-element elementor-element-e4b158f e-flex e-con-boxed e-con e-parent\" data-id=\"e4b158f\" data-element_type=\"container\">\n\t\t\t\t\t<div class=\"e-con-inner\">\n\t\t\t\t<div class=\"elementor-element elementor-element-181b639 elementor-widget elementor-widget-html\" data-id=\"181b639\" data-element_type=\"widget\" data-widget_type=\"html.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<iframe\r\n    id=\"bcIframe\"\r\n    width=\"100%\"\r\n    height=\"2000\"\r\n    scrolling=\"auto\"\r\n    style=\"border:none;display:block;\">\r\n<\/iframe>\r\n<script>\r\n(function() {\r\n    function formato(fecha) {\r\n        const y = fecha.getFullYear();\r\n        const m = String(fecha.getMonth() + 1).padStart(2, '0');\r\n        const d = String(fecha.getDate()).padStart(2, '0');\r\n        return `${y}-${m}-${d}`;\r\n    }\r\n    function etiqueta(fecha) {\r\n        const dias = [\"Sun\",\"Mon\",\"Tue\",\"Wed\",\"Thu\",\"Fri\",\"Sat\"];\r\n        const dd = String(fecha.getDate()).padStart(2, '0');\r\n        const mm = String(fecha.getMonth() + 1).padStart(2, '0');\r\n        const yy = String(fecha.getFullYear()).slice(-2);\r\n        return `${dias[fecha.getDay()]} ${dd}.${mm}.${yy}`;\r\n    }\r\n    function parseISO(str) {\r\n        \/\/ str esperado: YYYY-MM-DD\r\n        const [y, m, d] = str.split('-').map(Number);\r\n        return new Date(y, m - 1, d);\r\n    }\r\n\r\n    var base = 'https:\/\/secure.bookerclub.com\/cgi-bin\/index.pl?_state=Hotels&aid=284&oid=0&searchtype=main&itable=hotel&iindex=683&lang=en&currency=eur&entity=Meral+Units%2C+Fuengirola%2C+Andalusia%2C+Spain';\r\n\r\n    var hash = window.location.hash.replace('#', '');\r\n    var checkInDate, checkOutDate, rooms = 1, adults = 2, children = 0;\r\n\r\n    if (hash && hash.indexOf('CheckInDate') !== -1) {\r\n        \/\/ Viene del buscador de la home\r\n        var parsed = {};\r\n        hash.split('&').forEach(function(pair) {\r\n            var kv = pair.split('=');\r\n            parsed[decodeURIComponent(kv[0])] = decodeURIComponent(kv[1] || '');\r\n        });\r\n        checkInDate  = parseISO(parsed['CheckInDate']);\r\n        checkOutDate = parseISO(parsed['CheckOutDate']);\r\n        rooms    = parsed['Rooms']    || 1;\r\n        adults   = parsed['Adults']   || 2;\r\n        children = parsed['Children'] || 0;\r\n    } else {\r\n        \/\/ Entrada directa: fechas por defecto hoy \/ ma\u00f1ana\r\n        checkInDate  = new Date();\r\n        checkOutDate = new Date(checkInDate);\r\n        checkOutDate.setDate(checkInDate.getDate() + 1);\r\n    }\r\n\r\n    var params = 'CheckInDateLabel=' + encodeURIComponent(etiqueta(checkInDate))\r\n               + '&CheckInDate=' + formato(checkInDate)\r\n               + '&CheckOutDateLabel=' + encodeURIComponent(etiqueta(checkOutDate))\r\n               + '&CheckOutDate=' + formato(checkOutDate)\r\n               + '&Rooms=' + rooms\r\n               + '&Adults=' + adults\r\n               + '&Children=' + children\r\n               + '&Adults_1=' + adults\r\n               + '&Children_1=' + children\r\n               + '&ChildAge1_1=12&ChildAge2_1=12&ChildAge3_1=12&FIND=SEARCH';\r\n\r\n    document.getElementById('bcIframe').src = base + '&' + params;\r\n\r\n    \/\/ Resize autom\u00e1tico desde Bookerclub\r\n    window.addEventListener('message', function(e) {\r\n        if (e.origin !== 'https:\/\/secure.bookerclub.com') return;\r\n        try {\r\n            var data = JSON.parse(e.data);\r\n            var ht = (data.ifrHeight || 0) + 150;\r\n            if (ht > 150) document.getElementById('bcIframe').style.height = ht + 'px';\r\n        } catch (err) {}\r\n    }, false);\r\n})();\r\n<\/script>\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t","protected":false},"excerpt":{"rendered":"","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-3738","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/meralunits.com\/en\/wp-json\/wp\/v2\/pages\/3738","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/meralunits.com\/en\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/meralunits.com\/en\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/meralunits.com\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/meralunits.com\/en\/wp-json\/wp\/v2\/comments?post=3738"}],"version-history":[{"count":17,"href":"https:\/\/meralunits.com\/en\/wp-json\/wp\/v2\/pages\/3738\/revisions"}],"predecessor-version":[{"id":3851,"href":"https:\/\/meralunits.com\/en\/wp-json\/wp\/v2\/pages\/3738\/revisions\/3851"}],"wp:attachment":[{"href":"https:\/\/meralunits.com\/en\/wp-json\/wp\/v2\/media?parent=3738"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}