{"id":1458,"date":"2026-01-15T18:57:11","date_gmt":"2026-01-15T18:57:11","guid":{"rendered":"https:\/\/webshootco.com\/?page_id=1458"},"modified":"2026-01-15T20:06:50","modified_gmt":"2026-01-15T20:06:50","slug":"booking","status":"publish","type":"page","link":"https:\/\/webshootco.com\/fr\/booking\/","title":{"rendered":"Booking"},"content":{"rendered":"<div class=\"ws-booking-page\">\n    <div class=\"ws-card\">\n      <h1>Book an Appointment<\/h1>\n      <p class=\"ws-sub\">Select a date & time. Your request will be reviewed and confirmed.<\/p>\n\n      <form id=\"wsBookingForm\" class=\"ws-form\" action=\"\">\n        <div class=\"ws-grid\">\n          <div class=\"ws-field\">\n            <label>Full Name<\/label>\n            <input type=\"text\" name=\"name\" required placeholder=\"Your full name\">\n          <\/div>\n          <div class=\"ws-field\">\n            <label>Email<\/label>\n            <input type=\"email\" name=\"email\" required placeholder=\"your@email.com\">\n          <\/div>\n          <div class=\"ws-field\">\n            <label>Date<\/label>\n            <input type=\"date\" name=\"date\" id=\"wsDate\" required>\n          <\/div>\n          <div class=\"ws-field\">\n            <label>Temps<\/label>\n            <input type=\"time\" name=\"time\" required>\n          <\/div>\n        <\/div>\n\n        <button class=\"ws-btn\" type=\"submit\">Submit Booking Request<\/button>\n        <div id=\"wsMsg\" class=\"ws-msg\" hidden><\/div>\n      <input type=\"hidden\" name=\"trp-form-language\" value=\"fr\"\/><\/form>\n    <\/div>\n  <\/div>\n\n  <script>\n  (function(){\n    const ajaxUrl = \"https:\/\/webshootco.com\/wp-admin\/admin-ajax.php\";\n    const msgEl = document.getElementById(\"wsMsg\");\n    const dateEl = document.getElementById(\"wsDate\");\n\n    \/\/ 1) Fetch approved dates and disable them\n    fetch(ajaxUrl + \"?action=ws_disabled_dates\")\n      .then(r => r.json())\n      .then(data => {\n        if(!data.success) return;\n        const disabled = new Set(data.data.dates || []);\n        \/\/ HTML date input can't truly \"disable a list\" natively.\n        \/\/ We'll prevent selection if user picks a blocked date.\n        dateEl.addEventListener(\"change\", () => {\n          if(disabled.has(dateEl.value)){\n            dateEl.value = \"\";\n            alert(\"This date is not available. Please select another date.\");\n          }\n        });\n      });\n\n    \/\/ 2) Submit booking -> sends email to you\n    document.getElementById(\"wsBookingForm\").addEventListener(\"submit\", function(e){\n      e.preventDefault();\n      msgEl.hidden = true;\n\n      const fd = new FormData(this);\n      fd.append(\"action\",\"ws_submit_booking\");\n\n      fetch(ajaxUrl, { method:\"POST\", body: fd })\n        .then(r => r.json())\n        .then(data => {\n          msgEl.hidden = false;\n          msgEl.textContent = data?.data?.message || \"Done\";\n          msgEl.className = \"ws-msg \" + (data.success ? \"ok\" : \"err\");\n          if(data.success) this.reset();\n        })\n        .catch(() => {\n          msgEl.hidden = false;\n          msgEl.textContent = \"Error. Please try again.\";\n          msgEl.className = \"ws-msg err\";\n        });\n    });\n  })();\n  <\/script>\n\n  <style>\n    .ws-booking-page{min-height:100vh;background:#000;padding:40px 14px;display:flex;align-items:center;justify-content:center;font-family:Arial,sans-serif}\n    .ws-card{width:min(900px,100%);background:rgba(255,255,255,.06);border:1px solid rgba(255,255,255,.14);border-radius:16px;padding:26px 22px;box-shadow:0 14px 40px rgba(0,0,0,.45);color:#fff}\n    .ws-card h1{margin:0 0 8px;font-size:28px}\n    .ws-sub{margin:0 0 18px;color:rgba(255,255,255,.75);font-size:14px}\n    .ws-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:14px}\n    .ws-field label{display:block;font-size:13px;margin-bottom:6px;color:rgba(255,255,255,.85)}\n    .ws-field input{width:100%;background:rgba(255,255,255,.10);border:1px solid rgba(255,255,255,.20);border-radius:10px;padding:12px;color:#fff;outline:none}\n    .ws-field input::placeholder{color:rgba(255,255,255,.55)}\n    .ws-btn{width:100%;margin-top:16px;background:#3d4547;color:#fff;border:none;padding:14px 16px;border-radius:10px;font-weight:700;cursor:pointer;transition:.2s}\n    .ws-btn:hover{background:#505a5c}\n    .ws-msg{margin-top:12px;text-align:center;font-weight:700;padding:10px 12px;border-radius:10px}\n    .ws-msg.ok{background:rgba(155,231,176,.12);border:1px solid rgba(155,231,176,.35);color:#9be7b0}\n    .ws-msg.err{background:rgba(255,120,120,.10);border:1px solid rgba(255,120,120,.35);color:#ff9a9a}\n    @media (max-width:768px){.ws-grid{grid-template-columns:1fr}.ws-card{padding:22px 16px}}\n  <\/style>\n  \n\n\n\n<p><\/p>","protected":false},"excerpt":{"rendered":"","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"om_disable_all_campaigns":false,"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"class_list":["post-1458","page","type-page","status-publish","hentry"],"aioseo_notices":[],"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/webshootco.com\/fr\/wp-json\/wp\/v2\/pages\/1458","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/webshootco.com\/fr\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/webshootco.com\/fr\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/webshootco.com\/fr\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/webshootco.com\/fr\/wp-json\/wp\/v2\/comments?post=1458"}],"version-history":[{"count":7,"href":"https:\/\/webshootco.com\/fr\/wp-json\/wp\/v2\/pages\/1458\/revisions"}],"predecessor-version":[{"id":1471,"href":"https:\/\/webshootco.com\/fr\/wp-json\/wp\/v2\/pages\/1458\/revisions\/1471"}],"wp:attachment":[{"href":"https:\/\/webshootco.com\/fr\/wp-json\/wp\/v2\/media?parent=1458"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}