This commit is contained in:
Oliver committed 2025-10-25 05:44:21 -03:00
1 parent f9b40e6437
commit 82c97e721e
4 files changed
+12 -10

No files matched your search

+5 -4
View File
@@ -71,10 +71,11 @@ function createModal() {
<form id="buyForm" style="display: flex; flex-direction: column; gap: 15px;"> <form id="buyForm" style="display: flex; flex-direction: column; gap: 15px;">
<select name="location" id="locationSelect" required style="display: none; padding: 12px 15px; font-size: 16px; border: 1px solid #ccc; border-radius: 8px; outline: none;"> <select name="location" id="locationSelect" required style="display: none; padding: 12px 15px; font-size: 16px; border: 1px solid #ccc; border-radius: 8px; outline: none;">
<option value="">Select Location</option> <option value="">Select Location</option>
<option value="Boston">Boston</option> <option value="Boston">US, Boston</option>
<option value="Manchester">Manchester</option> <option value="Manchester">UK, Manchester</option>
<option value="Mumbai">Mumbai</option> <option value="Mumbai">IN, Mumbai</option>
<option value="Saopaulo">Sao Paulo</option> <option value="Saopaulo">BR, Sao Paulo</option>
<option value="Meppel">NL, Meppel</option>
</select> </select>
<input type="text" name="name" placeholder="Name" required style="padding: 12px 15px; border: 1px solid #ccc; border-radius: 8px;"> <input type="text" name="name" placeholder="Name" required style="padding: 12px 15px; border: 1px solid #ccc; border-radius: 8px;">
+1 -1
View File
@@ -1 +1 @@
const CATEGORY_CONFIG={3:{showLocation:!1,webhook:""},4:{showLocation:!0,webhook:"https://002-001-5dd6e535-4d1c-46bc-9bd9-42ad4bc5f082.odoo4projects.com/webhook/c76e6b4e-af2f-4bc3-9875-6460d0ffc8e3"},5:{showLocation:!1,webhook:"https://002-001-5dd6e535-4d1c-46bc-9bd9-42ad4bc5f082.odoo4projects.com/webhook/fd20e194-b821-4b1f-814f-7bb93ae16046"},7:{showLocation:!1,webhook:""}};function getCookie(e){const t=document.cookie.match(new RegExp("(^| )"+e+"=([^;]+)"));return t?decodeURIComponent(t[2]):null}function setCookieIfEmpty(e,t,o=90){if(!t)return;if(getCookie(e))return;const n=new Date;n.setTime(n.getTime()+24*o*60*60*1e3),document.cookie=`${e}=${encodeURIComponent(t)}; expires=${n.toUTCString()}; path=/; SameSite=Lax`}function addUtmFields(e){const t={utm_source:"homepage",utm_medium:"direct",utm_campaign:"none",utm_term:"",utm_content:""};["utm_source","utm_medium","utm_campaign","utm_term","utm_content"].forEach(o=>{let n=e.querySelector(`input[name="${o}"]`);n||(n=document.createElement("input"),n.type="hidden",n.name=o,e.appendChild(n)),n.value=getCookie(o)||t[o]})}function createModal(){const e=document.createElement("div");return e.id="buyNowModal",Object.assign(e.style,{position:"fixed",top:"0",left:"0",width:"100%",height:"100%",backgroundColor:"rgba(0,0,0,0.6)",display:"none",justifyContent:"center",alignItems:"center",zIndex:"1000"}),e.innerHTML='\n <div style="background: #fff; padding: 40px 30px; border-radius: 16px; max-width: 500px; width: 90%; position: relative; font-family: \'Arial\', sans-serif; box-shadow: 0 10px 25px rgba(0,0,0,0.2);">\n <span id="closeModal" style="position: absolute; top: 15px; right: 20px; cursor: pointer; font-weight: bold; font-size: 24px; color: #555;">&times;</span>\n <h2 style="margin-bottom: 15px; font-size: 24px; color: #333;">Order Details</h2>\n <p id="productText" style="margin-bottom: 25px; font-weight: 500; color: #555;"></p>\n\n <form id="buyForm" style="display: flex; flex-direction: column; gap: 15px;">\n <select name="location" id="locationSelect" required style="display: none; padding: 12px 15px; font-size: 16px; border: 1px solid #ccc; border-radius: 8px; outline: none;">\n <option value="">Select Location</option>\n <option value="Boston">Boston</option>\n <option value="Manchester">Manchester</option>\n <option value="Mumbai">Mumbai</option>\n <option value="Saopaulo">Sao Paulo</option>\n </select>\n\n <input type="text" name="name" placeholder="Name" required style="padding: 12px 15px; border: 1px solid #ccc; border-radius: 8px;">\n <input type="text" name="company" placeholder="Company" required style="padding: 12px 15px; border: 1px solid #ccc; border-radius: 8px;">\n <input type="text" name="country" placeholder="Country" required style="padding: 12px 15px; border: 1px solid #ccc; border-radius: 8px;">\n <input type="text" name="street" placeholder="Street" required style="padding: 12px 15px; border: 1px solid #ccc; border-radius: 8px;">\n <div style="display: flex; gap: 10px;">\n <input type="text" name="zip" placeholder="ZIP" required style="max-width: 100px; flex: 1 1 0; padding: 12px 10px; border: 1px solid #ccc; border-radius: 8px;">\n <input type="text" name="town" placeholder="Town" required style="flex: 2 1 0; padding: 12px 10px; border: 1px solid #ccc; border-radius: 8px;">\n </div>\n <input type="email" name="email" placeholder="Email" required style="padding: 12px 15px; border: 1px solid #ccc; border-radius: 8px;">\n <input type="hidden" name="product">\n <input type="hidden" name="price">\n <input type="hidden" name="id">\n <input type="hidden" name="category">\n\n <button id="submitBuy" type="submit" style="padding: 14px; background: #007BFF; color: #fff; border: none; border-radius: 8px; cursor: pointer; font-size: 18px; font-weight: bold;">Send Order</button>\n </form>\n\n <div id="confirmation" style="display: none; margin-top: 20px; padding: 20px; background-color: #e6ffed; color: #056608; border-radius: 12px; text-align: center; font-weight: 500;">\n <p>Thank you for your purchase! 🎉</p>\n <button id="closeConfirmation" style="margin-top: 10px; padding: 10px 20px; background: #007BFF; color: #fff; border: none; border-radius: 8px; cursor: pointer;">Close</button>\n </div>\n </div>\n ',document.body.appendChild(e),document.getElementById("closeModal").onclick=()=>e.style.display="none",document.getElementById("closeConfirmation").onclick=()=>{document.getElementById("confirmation").style.display="none",e.style.display="none"},e.onclick=t=>{t.target===e&&(e.style.display="none")},e}function openModal(e){const t=document.getElementById("buyNowModal"),o=t.querySelector("#buyForm"),n=t.querySelector("#confirmation");t.style.display="flex",o.style.display="flex",n.style.display="none";const i=e.split("/").filter(BooLine truncated const CATEGORY_CONFIG={3:{showLocation:!1,webhook:""},4:{showLocation:!0,webhook:"https://002-001-5dd6e535-4d1c-46bc-9bd9-42ad4bc5f082.odoo4projects.com/webhook/c76e6b4e-af2f-4bc3-9875-6460d0ffc8e3"},5:{showLocation:!1,webhook:"https://002-001-5dd6e535-4d1c-46bc-9bd9-42ad4bc5f082.odoo4projects.com/webhook/fd20e194-b821-4b1f-814f-7bb93ae16046"},7:{showLocation:!1,webhook:""}};function getCookie(e){const t=document.cookie.match(new RegExp("(^| )"+e+"=([^;]+)"));return t?decodeURIComponent(t[2]):null}function setCookieIfEmpty(e,t,o=90){if(!t)return;if(getCookie(e))return;const n=new Date;n.setTime(n.getTime()+24*o*60*60*1e3),document.cookie=`${e}=${encodeURIComponent(t)}; expires=${n.toUTCString()}; path=/; SameSite=Lax`}function addUtmFields(e){const t={utm_source:"homepage",utm_medium:"direct",utm_campaign:"none",utm_term:"",utm_content:""};["utm_source","utm_medium","utm_campaign","utm_term","utm_content"].forEach(o=>{let n=e.querySelector(`input[name="${o}"]`);n||(n=document.createElement("input"),n.type="hidden",n.name=o,e.appendChild(n)),n.value=getCookie(o)||t[o]})}function createModal(){const e=document.createElement("div");return e.id="buyNowModal",Object.assign(e.style,{position:"fixed",top:"0",left:"0",width:"100%",height:"100%",backgroundColor:"rgba(0,0,0,0.6)",display:"none",justifyContent:"center",alignItems:"center",zIndex:"1000"}),e.innerHTML='\n <div style="background: #fff; padding: 40px 30px; border-radius: 16px; max-width: 500px; width: 90%; position: relative; font-family: \'Arial\', sans-serif; box-shadow: 0 10px 25px rgba(0,0,0,0.2);">\n <span id="closeModal" style="position: absolute; top: 15px; right: 20px; cursor: pointer; font-weight: bold; font-size: 24px; color: #555;">&times;</span>\n <h2 style="margin-bottom: 15px; font-size: 24px; color: #333;">Order Details</h2>\n <p id="productText" style="margin-bottom: 25px; font-weight: 500; color: #555;"></p>\n\n <form id="buyForm" style="display: flex; flex-direction: column; gap: 15px;">\n <select name="location" id="locationSelect" required style="display: none; padding: 12px 15px; font-size: 16px; border: 1px solid #ccc; border-radius: 8px; outline: none;">\n <option value="">Select Location</option>\n <option value="Boston">US, Boston</option>\n <option value="Manchester">UK, Manchester</option>\n <option value="Mumbai">IN, Mumbai</option>\n <option value="Saopaulo">BR, Sao Paulo</option>\n <option value="Meppel">NL, Meppel</option>\n </select>\n\n <input type="text" name="name" placeholder="Name" required style="padding: 12px 15px; border: 1px solid #ccc; border-radius: 8px;">\n <input type="text" name="company" placeholder="Company" required style="padding: 12px 15px; border: 1px solid #ccc; border-radius: 8px;">\n <input type="text" name="country" placeholder="Country" required style="padding: 12px 15px; border: 1px solid #ccc; border-radius: 8px;">\n <input type="text" name="street" placeholder="Street" required style="padding: 12px 15px; border: 1px solid #ccc; border-radius: 8px;">\n <div style="display: flex; gap: 10px;">\n <input type="text" name="zip" placeholder="ZIP" required style="max-width: 100px; flex: 1 1 0; padding: 12px 10px; border: 1px solid #ccc; border-radius: 8px;">\n <input type="text" name="town" placeholder="Town" required style="flex: 2 1 0; padding: 12px 10px; border: 1px solid #ccc; border-radius: 8px;">\n </div>\n <input type="email" name="email" placeholder="Email" required style="padding: 12px 15px; border: 1px solid #ccc; border-radius: 8px;">\n <input type="hidden" name="product">\n <input type="hidden" name="price">\n <input type="hidden" name="id">\n <input type="hidden" name="category">\n\n <button id="submitBuy" type="submit" style="padding: 14px; background: #007BFF; color: #fff; border: none; border-radius: 8px; cursor: pointer; font-size: 18px; font-weight: bold;">Send Order</button>\n </form>\n\n <div id="confirmation" style="display: none; margin-top: 20px; padding: 20px; background-color: #e6ffed; color: #056608; border-radius: 12px; text-align: center; font-weight: 500;">\n <p>Thank you for your purchase! 🎉</p>\n <button id="closeConfirmation" style="margin-top: 10px; padding: 10px 20px; background: #007BFF; color: #fff; border: none; border-radius: 8px; cursor: pointer;">Close</button>\n </div>\n </div>\n ',document.body.appendChild(e),document.getElementById("closeModal").onclick=()=>e.style.display="none",document.getElementById("closeConfirmation").onclick=()=>{document.getElementById("confirmation").style.display="none",e.style.display="none"},e.onclick=t=>{t.target===e&&(e.style.display="none")},e}function openModal(e){const t=document.getElementById("buyNowModal"),o=t.querySelector("#buyForm"),n=t.querySelector("#confirmation");t.style.display="flex",o.styleLine truncated
+5 -4
View File
@@ -74,10 +74,11 @@ function tryNow_createModal() {
<select name="location" id="trynowLocationSelect" required style="padding: 12px 15px; font-size: 16px; border: 1px solid #ccc; border-radius: 8px; outline: none;"> <select name="location" id="trynowLocationSelect" required style="padding: 12px 15px; font-size: 16px; border: 1px solid #ccc; border-radius: 8px; outline: none;">
<option value="">Select Location</option> <option value="">Select Location</option>
<option value="Boston">Boston</option> <option value="Boston">US, Boston</option>
<option value="Manchester">Manchester</option> <option value="Manchester">UK, Manchester</option>
<option value="Mumbai">Mumbai</option> <option value="Mumbai">IN, Mumbai</option>
<option value="saopaulo">Sao Paulo</option> <option value="saopaulo">BR, Sao Paulo</option>
<option value="Meppel">NL, Meppel</option>
</select> </select>
<select name="product" required style="padding: 12px 15px; font-size: 16px; border: 1px solid #ccc; border-radius: 8px; outline: none;"> <select name="product" required style="padding: 12px 15px; font-size: 16px; border: 1px solid #ccc; border-radius: 8px; outline: none;">
+1 -1
View File
@@ -1 +1 @@
const TRYNOW_WEBHOOK_URL="https://002-001-5dd6e535-4d1c-46bc-9bd9-42ad4bc5f082.odoo4projects.com/webhook/c25169c6-4234-4b47-8e74-612b9539da0a";function getCookie(n){const t=`; ${document.cookie}`.split(`; ${n}=`);return 2===t.length?t.pop().split(";").shift():null}function addUtmFields(n){const t={utm_source:"homepage",utm_medium:"direct",utm_campaign:"none"};["utm_source","utm_medium","utm_campaign","utm_term","utm_content"].forEach(o=>{let e=n.querySelector(`input[name="${o}"]`);e||(e=document.createElement("input"),e.type="hidden",e.name=o,n.appendChild(e));const i=getCookie(o);e.value=i||t[o]||""})}function tryNow_createModal(){const n=document.createElement("div");n.id="trynowModal",n.style.position="fixed",n.style.top="0",n.style.left="0",n.style.width="100%",n.style.height="100%",n.style.backgroundColor="rgba(0,0,0,0.6)",n.style.display="none",n.style.justifyContent="center",n.style.alignItems="center",n.style.zIndex="1000",n.innerHTML='\n <div style="\n background: #ffffff; \n padding: 40px 30px; \n border-radius: 16px; \n max-width: 400px; \n width: 90%; \n position: relative; \n font-family: \'Arial\', sans-serif; \n box-shadow: 0 10px 25px rgba(0,0,0,0.2);\n ">\n <span id="trynowCloseModal" style="\n position: absolute; \n top: 15px; \n right: 20px; \n cursor: pointer; \n font-weight: bold; \n font-size: 24px;\n color: #555;\n ">&times;</span>\n \n <h2 style="margin-bottom: 20px; font-size: 24px; color: #333;">Order Details</h2>\n\n <form id="trynowForm" style="display: flex; flex-direction: column; gap: 15px;">\n <input type="email" name="email" placeholder="Email" required style="padding: 12px 15px; font-size: 16px; border: 1px solid #ccc; border-radius: 8px; outline: none;">\n\n <select name="location" id="trynowLocationSelect" required style="padding: 12px 15px; font-size: 16px; border: 1px solid #ccc; border-radius: 8px; outline: none;">\n <option value="">Select Location</option>\n <option value="Boston">Boston</option>\n <option value="Manchester">Manchester</option>\n <option value="Mumbai">Mumbai</option>\n <option value="saopaulo">Sao Paulo</option>\n </select>\n\n <select name="product" required style="padding: 12px 15px; font-size: 16px; border: 1px solid #ccc; border-radius: 8px; outline: none;">\n <option value="odoo_19" selected>ODOO</option>\n <option value="N8N">n8n</option>\n </select>\n\n <button type="submit" style="\n padding: 14px; \n background: #007BFF; \n color: #fff; \n border: none; \n border-radius: 8px; \n cursor: pointer; \n font-size: 18px; \n font-weight: bold;\n transition: background 0.3s;\n ">Start free Trial</button>\n </form>\n\n <div id="trynowConfirmation" style="\n display: none;\n margin-top: 20px;\n padding: 20px;\n background-color: #e6ffed;\n color: #056608;\n border-radius: 12px;\n text-align: center;\n font-weight: 500;\n ">\n <p>Thank you for your submission! 🎉</p>\n <button id="trynowCloseConfirmation" style="\n margin-top: 10px;\n padding: 10px 20px;\n background: #007BFF;\n color: #fff;\n border: none;\n border-radius: 8px;\n cursor: pointer;\n font-size: 16px;\n transition: background 0.3s;\n ">Close</button>\n </div>\n </div>\n ',document.body.appendChild(n);return addUtmFields(n.querySelector("#trynowForm")),document.getElementById("trynowCloseModal").onclick=()=>{n.style.display="none"},document.getElementById("trynowCloseConfirmation").onclick=()=>{document.getElementById("trynowConfirmation").style.display="none",n.style.display="none"},n.onclick=t=>{t.target===n&&(n.style.display="none")},n}function tryNow_handleFormSubmit(){const n=document.getElementById("trynowForm"),t=document.getElementById("trynowConfirmation");n.addEventListener("submit",async o=>{o.preventDefault(),addUtmFields(n);const e={};new FormData(n).forEach((n,t)=>e[t]=n);try{(await fetch(TRYNOW_WEBHOOK_URL,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)})).ok?(n.style.display="none",t.style.displLine truncated const TRYNOW_WEBHOOK_URL="https://002-001-5dd6e535-4d1c-46bc-9bd9-42ad4bc5f082.odoo4projects.com/webhook/c25169c6-4234-4b47-8e74-612b9539da0a";function getCookie(n){const t=`; ${document.cookie}`.split(`; ${n}=`);return 2===t.length?t.pop().split(";").shift():null}function addUtmFields(n){const t={utm_source:"homepage",utm_medium:"direct",utm_campaign:"none"};["utm_source","utm_medium","utm_campaign","utm_term","utm_content"].forEach(o=>{let e=n.querySelector(`input[name="${o}"]`);e||(e=document.createElement("input"),e.type="hidden",e.name=o,n.appendChild(e));const i=getCookie(o);e.value=i||t[o]||""})}function tryNow_createModal(){const n=document.createElement("div");n.id="trynowModal",n.style.position="fixed",n.style.top="0",n.style.left="0",n.style.width="100%",n.style.height="100%",n.style.backgroundColor="rgba(0,0,0,0.6)",n.style.display="none",n.style.justifyContent="center",n.style.alignItems="center",n.style.zIndex="1000",n.innerHTML='\n <div style="\n background: #ffffff; \n padding: 40px 30px; \n border-radius: 16px; \n max-width: 400px; \n width: 90%; \n position: relative; \n font-family: \'Arial\', sans-serif; \n box-shadow: 0 10px 25px rgba(0,0,0,0.2);\n ">\n <span id="trynowCloseModal" style="\n position: absolute; \n top: 15px; \n right: 20px; \n cursor: pointer; \n font-weight: bold; \n font-size: 24px;\n color: #555;\n ">&times;</span>\n \n <h2 style="margin-bottom: 20px; font-size: 24px; color: #333;">Order Details</h2>\n\n <form id="trynowForm" style="display: flex; flex-direction: column; gap: 15px;">\n <input type="email" name="email" placeholder="Email" required style="padding: 12px 15px; font-size: 16px; border: 1px solid #ccc; border-radius: 8px; outline: none;">\n\n <select name="location" id="trynowLocationSelect" required style="padding: 12px 15px; font-size: 16px; border: 1px solid #ccc; border-radius: 8px; outline: none;">\n <option value="">Select Location</option>\n <option value="Boston">US, Boston</option>\n <option value="Manchester">UK, Manchester</option>\n <option value="Mumbai">IN, Mumbai</option>\n <option value="saopaulo">BR, Sao Paulo</option>\n <option value="Meppel">NL, Meppel</option>\n </select>\n\n <select name="product" required style="padding: 12px 15px; font-size: 16px; border: 1px solid #ccc; border-radius: 8px; outline: none;">\n <option value="odoo_19" selected>ODOO</option>\n <option value="N8N">n8n</option>\n </select>\n\n <button type="submit" style="\n padding: 14px; \n background: #007BFF; \n color: #fff; \n border: none; \n border-radius: 8px; \n cursor: pointer; \n font-size: 18px; \n font-weight: bold;\n transition: background 0.3s;\n ">Start free Trial</button>\n </form>\n\n <div id="trynowConfirmation" style="\n display: none;\n margin-top: 20px;\n padding: 20px;\n background-color: #e6ffed;\n color: #056608;\n border-radius: 12px;\n text-align: center;\n font-weight: 500;\n ">\n <p>Thank you for your submission! 🎉</p>\n <button id="trynowCloseConfirmation" style="\n margin-top: 10px;\n padding: 10px 20px;\n background: #007BFF;\n color: #fff;\n border: none;\n border-radius: 8px;\n cursor: pointer;\n font-size: 16px;\n transition: background 0.3s;\n ">Close</button>\n </div>\n </div>\n ',document.body.appendChild(n);return addUtmFields(n.querySelector("#trynowForm")),document.getElementById("trynowCloseModal").onclick=()=>{n.style.display="none"},document.getElementById("trynowCloseConfirmation").onclick=()=>{document.getElementById("trynowConfirmation").style.display="none",n.style.display="none"},n.onclick=t=>{t.target===n&&(n.style.display="none")},n}function tryNow_handleFormSubmit(){const n=document.getElementById("trynowForm"),t=document.getElementById("trynowConfirmation");n.addEventListener("submit",async o=>{o.preventDefault(),addUtmFields(n);const e={};new FormData(n).forEach((n,t)=>e[t]=n);try{(await fetch(TRYNOW_WEBHOOK_URL,{method:"POST",headers:{"Content-Type":"appliLine truncated