make form buy-by-phone
This commit is contained in:
381
.vscode/ftp-kr.sync.cache.json
vendored
381
.vscode/ftp-kr.sync.cache.json
vendored
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"ftp://dedyk8.cyber-folks.pl@www@masimmo.pl": {
|
||||
"ftp://www@masimmo.pl@dedyk8.cyber-folks.pl": {
|
||||
"public_html": {
|
||||
"admin264x7t1sv": {},
|
||||
"app": {},
|
||||
@@ -134,8 +134,8 @@
|
||||
"img": {},
|
||||
"import-drewmax.php": {
|
||||
"type": "-",
|
||||
"size": 34786,
|
||||
"lmtime": 1766057916974,
|
||||
"size": 33916,
|
||||
"lmtime": 1768288646185.91,
|
||||
"modified": false
|
||||
},
|
||||
"import-product.php": {
|
||||
@@ -148,7 +148,7 @@
|
||||
"type": "-",
|
||||
"size": 1681,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
"modified": true
|
||||
},
|
||||
"init.php": {
|
||||
"type": "-",
|
||||
@@ -202,198 +202,22 @@
|
||||
"modified": true
|
||||
},
|
||||
"modules": {
|
||||
"gm_omniprice": {
|
||||
"CHANGELOG": {
|
||||
"type": "-",
|
||||
"size": 5258,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"cleanup.php": {
|
||||
"type": "-",
|
||||
"size": 350,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"config_pl.xml": {
|
||||
"type": "-",
|
||||
"size": 556,
|
||||
"lmtime": 1766048950150,
|
||||
"modified": false
|
||||
},
|
||||
"controllers": {
|
||||
"front": {
|
||||
"cron.php": {
|
||||
"type": "-",
|
||||
"size": 4477,
|
||||
"lmtime": 1766048950152,
|
||||
"modified": false
|
||||
"blockreassurance": {
|
||||
"views": {
|
||||
"templates": {
|
||||
"hook": {
|
||||
"displayBlockProduct.tpl": {
|
||||
"type": "-",
|
||||
"size": 4356,
|
||||
"lmtime": 1768288646186.5957,
|
||||
"modified": false
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"cron.php": {
|
||||
"type": "-",
|
||||
"size": 1492,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
".DS_Store": {
|
||||
"type": "-",
|
||||
"size": 6148,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"fill.php": {
|
||||
"type": "-",
|
||||
"size": 348,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"gm_omniprice.php": {
|
||||
"type": "-",
|
||||
"size": 100447,
|
||||
"lmtime": 1766048950155,
|
||||
"modified": false
|
||||
},
|
||||
"index.php": {
|
||||
"type": "-",
|
||||
"size": 1304,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"logo.png": {
|
||||
"type": "-",
|
||||
"size": 4539,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"logo.webp": {
|
||||
"type": "-",
|
||||
"size": 1980,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"template.php": {
|
||||
"type": "-",
|
||||
"size": 1926,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"translations": {
|
||||
"de.php": {
|
||||
"type": "-",
|
||||
"size": 9540,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"es.php": {
|
||||
"type": "-",
|
||||
"size": 9589,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"fr.php": {
|
||||
"type": "-",
|
||||
"size": 9585,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"it.php": {
|
||||
"type": "-",
|
||||
"size": 9493,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"nl.php": {
|
||||
"type": "-",
|
||||
"size": 0,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"pl.php": {
|
||||
"type": "-",
|
||||
"size": 9307,
|
||||
"lmtime": 1766048950156,
|
||||
"modified": false
|
||||
}
|
||||
},
|
||||
"upgrade": {},
|
||||
"views": {}
|
||||
}
|
||||
},
|
||||
"override": {
|
||||
"classes": {
|
||||
"assets": {},
|
||||
"cache": {},
|
||||
"Category.php": {
|
||||
"type": "-",
|
||||
"size": 1103,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"checkout": {},
|
||||
"CMSCategory.php": {
|
||||
"type": "-",
|
||||
"size": 1058,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"container": {},
|
||||
"controller": {},
|
||||
"db": {},
|
||||
"Dispatcher.php": {
|
||||
"type": "-",
|
||||
"size": 11680,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
".DS_Store": {
|
||||
"type": "-",
|
||||
"size": 10244,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"exception": {},
|
||||
"form": {},
|
||||
"helper": {},
|
||||
"index.php": {
|
||||
"type": "-",
|
||||
"size": 1369,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"lang": {},
|
||||
"Link.php": {
|
||||
"type": "-",
|
||||
"size": 17545,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"log": {},
|
||||
"Manufacturer.php": {
|
||||
"type": "-",
|
||||
"size": 1081,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"module": {},
|
||||
"order": {},
|
||||
"pdf": {},
|
||||
"range": {},
|
||||
"shop": {},
|
||||
"Smarty": {},
|
||||
"stock": {},
|
||||
"Supplier.php": {
|
||||
"type": "-",
|
||||
"size": 1061,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"tax": {},
|
||||
"tree": {},
|
||||
"webservice": {}
|
||||
}
|
||||
}
|
||||
},
|
||||
"override": {},
|
||||
"pdf": {},
|
||||
"phpstan.neon.dist": {
|
||||
"type": "-",
|
||||
@@ -405,12 +229,12 @@
|
||||
"type": "-",
|
||||
"size": 3372,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
"modified": true
|
||||
},
|
||||
"sitemaps": {},
|
||||
"sitemap_shop_1.xml": {
|
||||
"type": "-",
|
||||
"size": 827,
|
||||
"size": 968,
|
||||
"lmtime": 0,
|
||||
"modified": true
|
||||
},
|
||||
@@ -423,6 +247,114 @@
|
||||
"src": {},
|
||||
"themes": {
|
||||
"classic": {
|
||||
"modules": {
|
||||
"ps_linklist": {
|
||||
"views": {
|
||||
"templates": {
|
||||
"hook": {
|
||||
"linkblock.tpl": {
|
||||
"type": "-",
|
||||
"size": 2203,
|
||||
"lmtime": 1759826160000,
|
||||
"modified": false
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"templates": {
|
||||
"catalog": {
|
||||
"listing": {
|
||||
"best-sales.tpl": {
|
||||
"type": "-",
|
||||
"size": 214,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"category.tpl": {
|
||||
"type": "-",
|
||||
"size": 1298,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"manufacturer.tpl": {
|
||||
"type": "-",
|
||||
"size": 1622,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"new-products.tpl": {
|
||||
"type": "-",
|
||||
"size": 215,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"prices-drop.tpl": {
|
||||
"type": "-",
|
||||
"size": 214,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"product-list.tpl": {
|
||||
"type": "-",
|
||||
"size": 4401,
|
||||
"lmtime": 1759829696632.9082,
|
||||
"modified": false
|
||||
},
|
||||
"search.tpl": {
|
||||
"type": "-",
|
||||
"size": 581,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"supplier.tpl": {
|
||||
"type": "-",
|
||||
"size": 1493,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
}
|
||||
}
|
||||
},
|
||||
"layouts": {
|
||||
"layout-both-columns.tpl": {
|
||||
"type": "-",
|
||||
"size": 3772,
|
||||
"lmtime": 1759830163474.185,
|
||||
"modified": false
|
||||
},
|
||||
"layout-content-only.tpl": {
|
||||
"type": "-",
|
||||
"size": 1556,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"layout-error.tpl": {
|
||||
"type": "-",
|
||||
"size": 1844,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"layout-full-width.tpl": {
|
||||
"type": "-",
|
||||
"size": 1482,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"layout-left-column.tpl": {
|
||||
"type": "-",
|
||||
"size": 1689,
|
||||
"lmtime": 1759830255906.7522,
|
||||
"modified": false
|
||||
},
|
||||
"layout-right-column.tpl": {
|
||||
"type": "-",
|
||||
"size": 1487,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
}
|
||||
}
|
||||
},
|
||||
"assets": {
|
||||
"css": {
|
||||
"00b1fb69fb78ff50fd555de80b2fb45e.ttf": {
|
||||
@@ -644,19 +576,19 @@
|
||||
"custom.css": {
|
||||
"type": "-",
|
||||
"size": 91828,
|
||||
"lmtime": 1766048950158,
|
||||
"lmtime": 1765895938673.4114,
|
||||
"modified": false
|
||||
},
|
||||
"custom.css.map": {
|
||||
"type": "-",
|
||||
"size": 25242,
|
||||
"lmtime": 0,
|
||||
"lmtime": 1765895938673.352,
|
||||
"modified": false
|
||||
},
|
||||
"custom.scss": {
|
||||
"type": "-",
|
||||
"size": 79358,
|
||||
"lmtime": 1766048950160,
|
||||
"lmtime": 1765895938432.5369,
|
||||
"modified": false
|
||||
},
|
||||
"dce0916af972e3040aa191f74b17dd46.woff2": {
|
||||
@@ -721,6 +653,55 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"core.js": {
|
||||
"type": "-",
|
||||
"size": 477381,
|
||||
"lmtime": 1768288646189.247,
|
||||
"modified": false
|
||||
},
|
||||
"core.js.LICENSE.txt": {
|
||||
"type": "-",
|
||||
"size": 1664,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"debug.tpl": {
|
||||
"type": "-",
|
||||
"size": 5064,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
".DS_Store": {
|
||||
"type": "-",
|
||||
"size": 6148,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
".htaccess": {
|
||||
"type": "-",
|
||||
"size": 242,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"index.php": {
|
||||
"type": "-",
|
||||
"size": 1369,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"javascript.tpl": {
|
||||
"type": "-",
|
||||
"size": 1583,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
},
|
||||
"_libraries": {},
|
||||
"package-lock.json": {
|
||||
"type": "-",
|
||||
"size": 235491,
|
||||
"lmtime": 0,
|
||||
"modified": false
|
||||
}
|
||||
},
|
||||
"tmp": {},
|
||||
@@ -728,9 +709,9 @@
|
||||
"translations": {},
|
||||
"update_price_log.csv": {
|
||||
"type": "-",
|
||||
"size": 24168,
|
||||
"lmtime": 1765784209430,
|
||||
"modified": true
|
||||
"size": 23674,
|
||||
"lmtime": 1768288646190.215,
|
||||
"modified": false
|
||||
},
|
||||
"upload": {},
|
||||
"var": {},
|
||||
|
||||
90
buy-by-phone.php
Normal file
90
buy-by-phone.php
Normal file
@@ -0,0 +1,90 @@
|
||||
<?php
|
||||
|
||||
use PHPMailer\PHPMailer\PHPMailer;
|
||||
use PHPMailer\PHPMailer\Exception;
|
||||
|
||||
//required files
|
||||
require 'phpmailer/src/Exception.php';
|
||||
require 'phpmailer/src/PHPMailer.php';
|
||||
require 'phpmailer/src/SMTP.php';
|
||||
|
||||
$recaptcha_key = '6LeJAUUsAAAAAIyCrwFMrsw9yQLPgnCWCOHPcjc8';
|
||||
$settings = array();
|
||||
|
||||
$settings_masimmo = array(
|
||||
'email_mail' => 'sklep@drmaterac.pl',
|
||||
'email_host' => 'serwer2140447.home.pl',
|
||||
'email_login' => 'sklep@drmaterac.pl',
|
||||
'email_password' => '8njIZnAb',
|
||||
'email_port' => 465,
|
||||
);
|
||||
|
||||
if(isset($_POST['g-recaptcha-response']))
|
||||
$captcha=$_POST['g-recaptcha-response'];
|
||||
|
||||
$response = json_decode(file_get_contents("https://www.google.com/recaptcha/api/siteverify?secret=".$recaptcha_key."&response=".$captcha."&remoteip=".$_SERVER['REMOTE_ADDR']), true);
|
||||
if($response['success'] == false) {
|
||||
echo '<p>Weryfikacja reCAPTCHA nie powiodła się. Proszę spróbować ponownie.</p>'; exit;
|
||||
} else {
|
||||
if (isset($_POST['buy-by-phone-name'])) {
|
||||
$settings = $settings_masimmo;
|
||||
|
||||
$name = $_POST['buy-by-phone-name'];
|
||||
$phone = $_POST['buy-by-phone-phone'];
|
||||
$mailFrom = $_POST['buy-by-phone-mail-from'];
|
||||
$productName = $_POST['buy-by-phone-product-name'];
|
||||
$productURI = $_POST['buy-by-phone-product-uri'];
|
||||
|
||||
$contact_time = $_POST['contact-time'];
|
||||
$buy_by_phone_need_advice = $_POST['buy-by-phone-need-advice'];
|
||||
$product_to_buy = $_POST['product-to-buy'];
|
||||
$shipping_address = $_POST['shipping-address'];
|
||||
$phone_for_courier = $_POST['phone-for-courier'];
|
||||
$email = $_POST['email'];
|
||||
$comments_to_order = $_POST['comments-to-order'];
|
||||
|
||||
$mail = new PHPMailer();
|
||||
|
||||
//Server settings
|
||||
$mail->isSMTP();
|
||||
$mail->Host = $settings['email_host'];
|
||||
$mail->SMTPAuth = true;
|
||||
$mail->Username = $settings['email_login'];
|
||||
$mail->Password = $settings['email_password'];
|
||||
$mail->SMTPSecure = 'ssl';
|
||||
$mail->Port = $settings['email_port'];
|
||||
$mail->CharSet = "UTF-8";
|
||||
|
||||
//Recipients
|
||||
$mail->setFrom($settings['email_mail'], $mailFrom);
|
||||
$mail->addAddress('mci@drmaterac.pl');
|
||||
$mail->addAddress('sklep@masimmo.pl');
|
||||
|
||||
if (!empty($email)) {
|
||||
$mail->addAddress($email);
|
||||
}
|
||||
|
||||
//Content
|
||||
$mail->isHTML(true); //Set email format to HTML
|
||||
$mail->Subject = $mailFrom; // email subject headings
|
||||
$mail->Body = '<p>Temat: Zamówienie przez telefon</p>' .
|
||||
'</p>Imię: ' . $name . '</p>' .
|
||||
'</p>Telefon: ' . $phone . '</p>' .
|
||||
'</p>Produkt: ' . $productName . '</p>' .
|
||||
'</p>Adres produktu: ' . $productURI . '</p>' .
|
||||
'</p>Preferowana data/godzina kontaktu: ' . $contact_time . '</p>' .
|
||||
'</p>Potrzebuję porady odnośnie doboru produktu: ' . $buy_by_phone_need_advice . '</p>' .
|
||||
'</p>Produkt jaki chcę kupić: ' . $product_to_buy . '</p>' .
|
||||
'</p>Adres do wysyłki: ' . $shipping_address . '</p>' .
|
||||
'</p>Numer telefonu dla kuriera: ' . $phone_for_courier . '</p>' .
|
||||
'</p>E-mail: ' . $email . '</p>' .
|
||||
'</p>Uwagi do zamówienia: ' . $comments_to_order . '</p>';
|
||||
|
||||
// Success sent message alert
|
||||
if ($mail->send()) {
|
||||
echo '<p>Formularz został pomyślnie wysłany.</p><p>Wkrótce się skontaktujemy</p>';
|
||||
} else {
|
||||
echo '<p>Błąd podczas wysyłania wiadomości</p>';
|
||||
}
|
||||
}
|
||||
};
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -4537,3 +4537,217 @@ section#checkout-payment-step {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#buy-by-phone-popup {
|
||||
position: fixed;
|
||||
inset: 0;
|
||||
z-index: 999999;
|
||||
opacity: 0;
|
||||
visibility: hidden;
|
||||
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
transition: opacity 250ms ease, visibility 250ms ease;
|
||||
overflow: auto;
|
||||
|
||||
&.active {
|
||||
opacity: 1;
|
||||
visibility: visible;
|
||||
}
|
||||
|
||||
&::before {
|
||||
content: '';
|
||||
position: fixed;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
background: rgba(0, 0, 0, 0.2);
|
||||
backdrop-filter: blur(2px);
|
||||
}
|
||||
|
||||
.buy-by-phone-popup--wrapper {
|
||||
position: relative;
|
||||
width: 100%;
|
||||
max-width: 700px;
|
||||
padding: 30px;
|
||||
background: #fff;
|
||||
border: 1px solid #e5e5e5;
|
||||
border-radius: 5px;
|
||||
z-index: 1;
|
||||
|
||||
.popup-header {
|
||||
position: relative;
|
||||
|
||||
&--close {
|
||||
position: absolute;
|
||||
top: -25px;
|
||||
right: -20px;
|
||||
|
||||
.close-popup {
|
||||
font-size: 16px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.popup-body {
|
||||
display: grid;
|
||||
grid-template-columns: 1fr 1fr;
|
||||
max-height: calc(100vh - 130px);
|
||||
overflow-y: auto;
|
||||
padding: 10px 10px 10px 0;
|
||||
column-gap: 20px;
|
||||
|
||||
.popup-body--left {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
.popup-img {
|
||||
.product-cover {
|
||||
width: 100%;
|
||||
max-width: fit-content;
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.popup-body--right {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
flex-direction: column;
|
||||
|
||||
p {
|
||||
color: #000;
|
||||
font-size: 14px;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.form-group {
|
||||
margin-bottom: 5px;
|
||||
|
||||
.form-control {
|
||||
border-radius: 3px;
|
||||
|
||||
&.form-control-name,
|
||||
&.form-control-phone {
|
||||
&::placeholder {
|
||||
color: #000;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&.form-group-radio {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
gap: 15px;
|
||||
|
||||
.radio-inline {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 5px;
|
||||
|
||||
input[type='radio'] {
|
||||
width: 20px;
|
||||
height: 20px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&.form-group-polityka {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
gap: 10px;
|
||||
align-items: baseline;
|
||||
|
||||
input#polityka {
|
||||
width: fit-content;
|
||||
}
|
||||
|
||||
label {
|
||||
text-align: left;
|
||||
font-size: 10px;
|
||||
margin-bottom: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.form-cols {
|
||||
display: grid;
|
||||
grid-template-columns: 1fr 1fr;
|
||||
column-gap: 5px;
|
||||
font-size: 16px;
|
||||
}
|
||||
|
||||
.popup-body-top {
|
||||
> p {
|
||||
color: #e79332;
|
||||
|
||||
> a {
|
||||
color: #e79332;
|
||||
text-decoration: underline;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.popup-input-alert {
|
||||
color: #ff0000;
|
||||
}
|
||||
}
|
||||
|
||||
@media (max-width: 700px) {
|
||||
grid-template-columns: 1fr;
|
||||
|
||||
.popup-body--left {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.popup-alert {
|
||||
display: none;
|
||||
position: absolute;
|
||||
inset: 0;
|
||||
|
||||
&.active {
|
||||
display: block;
|
||||
}
|
||||
|
||||
&::after {
|
||||
content: '';
|
||||
position: absolute;
|
||||
inset: -1px;
|
||||
background: rgba(0, 0, 0, 0.3);
|
||||
border-radius: 5px;
|
||||
backdrop-filter: blur(2px);
|
||||
}
|
||||
|
||||
.popup-alert-wrapper {
|
||||
position: fixed;
|
||||
left: 50%;
|
||||
top: 50%;
|
||||
transform: translate(-50%, -50%);
|
||||
padding: 30px;
|
||||
background: #fff;
|
||||
border: 1px solid #e5e5e5;
|
||||
border-radius: 5px;
|
||||
z-index: 1;
|
||||
width: 100%;
|
||||
max-width: 300px;
|
||||
|
||||
.popup-alert-close {
|
||||
position: absolute;
|
||||
top: 5px;
|
||||
right: 10px;
|
||||
font-size: 16px;
|
||||
}
|
||||
|
||||
.popup-alert-data {
|
||||
p {
|
||||
margin: 10px 0 0 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -295,202 +295,337 @@ jQuery(document).ready(function ($) {
|
||||
$btnBox.removeClass('active')
|
||||
}
|
||||
})
|
||||
});
|
||||
})
|
||||
|
||||
/* custom.js — LEKKIE przeniesienie sekcji .custom-buttons
|
||||
Góra: klony top-level bloków (dzieci #category-description) z WYŁĄCZNIE .custom-buttons
|
||||
Dół: oryginał bez sekcji .custom-buttons
|
||||
NIE DZIAŁA podczas edycji w Elementor/Creative Elements.
|
||||
*/
|
||||
(function () {
|
||||
'use strict';
|
||||
;(function () {
|
||||
'use strict'
|
||||
|
||||
// --- GUARD: nie uruchamiaj w trybie edycji (Elementor / Creative Elements) ---
|
||||
function isEditing() {
|
||||
var href = String(location.href || '');
|
||||
var ref = String(document.referrer || '');
|
||||
var topHref = '';
|
||||
try { topHref = String(window.top.location.href || ''); } catch (e) { /* cross-origin fallback */ }
|
||||
// --- GUARD: nie uruchamiaj w trybie edycji (Elementor / Creative Elements) ---
|
||||
function isEditing() {
|
||||
var href = String(location.href || '')
|
||||
var ref = String(document.referrer || '')
|
||||
var topHref = ''
|
||||
try {
|
||||
topHref = String(window.top.location.href || '')
|
||||
} catch (e) {
|
||||
/* cross-origin fallback */
|
||||
}
|
||||
|
||||
// Zbiorcza „słomka” do przeszukania (ramka, referrer, parent)
|
||||
var haystack = (href + ' ' + ref + ' ' + topHref).toLowerCase();
|
||||
// Zbiorcza „słomka” do przeszukania (ramka, referrer, parent)
|
||||
var haystack = (href + ' ' + ref + ' ' + topHref).toLowerCase()
|
||||
|
||||
// 1) Najpewniejsze: kontroler zaplecza CE
|
||||
if (haystack.indexOf('controller=adminceeditor') !== -1) return true;
|
||||
// 1) Najpewniejsze: kontroler zaplecza CE
|
||||
if (haystack.indexOf('controller=adminceeditor') !== -1) return true
|
||||
|
||||
// 2) Podgląd/edycja elementora/CE
|
||||
if (haystack.indexOf('elementor-preview') !== -1) return true;
|
||||
// 2) Podgląd/edycja elementora/CE
|
||||
if (haystack.indexOf('elementor-preview') !== -1) return true
|
||||
|
||||
// 3) Klasy/markery edytora na body w tej ramce
|
||||
var body = document.body;
|
||||
if (body && /\b(elementor-editor-active|ce-editor-active|ce-editing)\b/i.test(body.className)) return true;
|
||||
// 3) Klasy/markery edytora na body w tej ramce
|
||||
var body = document.body
|
||||
if (
|
||||
body &&
|
||||
/\b(elementor-editor-active|ce-editor-active|ce-editing)\b/i.test(
|
||||
body.className
|
||||
)
|
||||
)
|
||||
return true
|
||||
|
||||
// 4) Panele edytora w oknie nadrzędnym (gdy front leci w iframe)
|
||||
if (window.self !== window.top) {
|
||||
try {
|
||||
if (window.top.document.querySelector('#elementor-panel, .elementor-panel, #ce-editor, .ce-editor, .ce-panel')) {
|
||||
return true;
|
||||
}
|
||||
} catch (e) { /* ignoruj brak dostępu */ }
|
||||
}
|
||||
// 4) Panele edytora w oknie nadrzędnym (gdy front leci w iframe)
|
||||
if (window.self !== window.top) {
|
||||
try {
|
||||
if (
|
||||
window.top.document.querySelector(
|
||||
'#elementor-panel, .elementor-panel, #ce-editor, .ce-editor, .ce-panel'
|
||||
)
|
||||
) {
|
||||
return true
|
||||
}
|
||||
} catch (e) {
|
||||
/* ignoruj brak dostępu */
|
||||
}
|
||||
}
|
||||
|
||||
// 5) Ręczny wyłącznik
|
||||
if (window.__CE_DISABLE_MOVE === true) return true;
|
||||
// 5) Ręczny wyłącznik
|
||||
if (window.__CE_DISABLE_MOVE === true) return true
|
||||
|
||||
return false;
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
// Wstaw ZARAZ po definicji isEditing()
|
||||
if (isEditing()) return;
|
||||
// Wstaw ZARAZ po definicji isEditing()
|
||||
if (isEditing()) return
|
||||
|
||||
var SOURCE_SEL = '#category-description';
|
||||
var TARGET_SEL = '.row.\\31 11'; // .row.111 (esc)
|
||||
var WRAP_ID = 'moved-category-structure';
|
||||
var BUTTON_SEC = 'section.custom-buttons, section.custom-buttons1';
|
||||
var ANY_SEC = 'section'; // lub 'section.elementor-top-section' jeśli chcesz zawęzić
|
||||
var SOURCE_SEL = '#category-description'
|
||||
var TARGET_SEL = '.row.\\31 11' // .row.111 (esc)
|
||||
var WRAP_ID = 'moved-category-structure'
|
||||
var BUTTON_SEC = 'section.custom-buttons, section.custom-buttons1'
|
||||
var ANY_SEC = 'section' // lub 'section.elementor-top-section' jeśli chcesz zawęzić
|
||||
|
||||
var didFinish = false;
|
||||
var obs = null;
|
||||
var debounceId = null;
|
||||
var didFinish = false
|
||||
var obs = null
|
||||
var debounceId = null
|
||||
|
||||
function ensureWrapper(target) {
|
||||
var wrap = document.getElementById(WRAP_ID);
|
||||
if (!wrap) {
|
||||
wrap = document.createElement('div');
|
||||
wrap.id = WRAP_ID;
|
||||
wrap.className = 'moved-category-structure';
|
||||
target.parentNode.insertBefore(wrap, target);
|
||||
}
|
||||
return wrap;
|
||||
}
|
||||
function ensureWrapper(target) {
|
||||
var wrap = document.getElementById(WRAP_ID)
|
||||
if (!wrap) {
|
||||
wrap = document.createElement('div')
|
||||
wrap.id = WRAP_ID
|
||||
wrap.className = 'moved-category-structure'
|
||||
target.parentNode.insertBefore(wrap, target)
|
||||
}
|
||||
return wrap
|
||||
}
|
||||
|
||||
function topLevelBlocks(src) {
|
||||
var out = [];
|
||||
for (var i = 0; i < src.children.length; i++) {
|
||||
var el = src.children[i];
|
||||
if (el.nodeType === 1) out.push(el);
|
||||
}
|
||||
return out;
|
||||
}
|
||||
function topLevelBlocks(src) {
|
||||
var out = []
|
||||
for (var i = 0; i < src.children.length; i++) {
|
||||
var el = src.children[i]
|
||||
if (el.nodeType === 1) out.push(el)
|
||||
}
|
||||
return out
|
||||
}
|
||||
|
||||
function cloneBlockWithOnlyButtons(block) {
|
||||
var clone = block.cloneNode(true);
|
||||
clone.querySelectorAll(ANY_SEC + ':not(.custom-buttons):not(.custom-buttons1)').forEach(function (sec) {
|
||||
sec.remove();
|
||||
});
|
||||
clone.querySelectorAll('.ce-edit-btn, .ce-edit-outline').forEach(function (n) { n.remove(); });
|
||||
if (!clone.querySelector(BUTTON_SEC)) return null;
|
||||
return clone;
|
||||
}
|
||||
function cloneBlockWithOnlyButtons(block) {
|
||||
var clone = block.cloneNode(true)
|
||||
clone
|
||||
.querySelectorAll(ANY_SEC + ':not(.custom-buttons):not(.custom-buttons1)')
|
||||
.forEach(function (sec) {
|
||||
sec.remove()
|
||||
})
|
||||
clone
|
||||
.querySelectorAll('.ce-edit-btn, .ce-edit-outline')
|
||||
.forEach(function (n) {
|
||||
n.remove()
|
||||
})
|
||||
if (!clone.querySelector(BUTTON_SEC)) return null
|
||||
return clone
|
||||
}
|
||||
|
||||
function syncOnce() {
|
||||
if (didFinish) return true;
|
||||
function syncOnce() {
|
||||
if (didFinish) return true
|
||||
|
||||
var src = document.querySelector(SOURCE_SEL);
|
||||
var target = document.querySelector(TARGET_SEL);
|
||||
if (!src || !target) return false;
|
||||
var src = document.querySelector(SOURCE_SEL)
|
||||
var target = document.querySelector(TARGET_SEL)
|
||||
if (!src || !target) return false
|
||||
|
||||
var blocks = topLevelBlocks(src);
|
||||
var blocksWithButtons = blocks.filter(function (b) { return !!b.querySelector(BUTTON_SEC); });
|
||||
if (!blocksWithButtons.length) return false;
|
||||
var blocks = topLevelBlocks(src)
|
||||
var blocksWithButtons = blocks.filter(function (b) {
|
||||
return !!b.querySelector(BUTTON_SEC)
|
||||
})
|
||||
if (!blocksWithButtons.length) return false
|
||||
|
||||
var wrap = ensureWrapper(target);
|
||||
var wrap = ensureWrapper(target)
|
||||
|
||||
var frag = document.createDocumentFragment();
|
||||
blocksWithButtons.forEach(function (b) {
|
||||
var prunedClone = cloneBlockWithOnlyButtons(b);
|
||||
if (prunedClone) frag.appendChild(prunedClone);
|
||||
});
|
||||
var frag = document.createDocumentFragment()
|
||||
blocksWithButtons.forEach(function (b) {
|
||||
var prunedClone = cloneBlockWithOnlyButtons(b)
|
||||
if (prunedClone) frag.appendChild(prunedClone)
|
||||
})
|
||||
|
||||
if (!frag.firstChild) return false;
|
||||
if (!frag.firstChild) return false
|
||||
|
||||
while (wrap.firstChild) wrap.removeChild(wrap.firstChild);
|
||||
wrap.appendChild(frag);
|
||||
while (wrap.firstChild) wrap.removeChild(wrap.firstChild)
|
||||
wrap.appendChild(frag)
|
||||
|
||||
src.querySelectorAll(BUTTON_SEC).forEach(function (sec) {
|
||||
if (sec && sec.parentNode) sec.parentNode.removeChild(sec);
|
||||
});
|
||||
src.querySelectorAll(BUTTON_SEC).forEach(function (sec) {
|
||||
if (sec && sec.parentNode) sec.parentNode.removeChild(sec)
|
||||
})
|
||||
|
||||
didFinish = true;
|
||||
if (obs) obs.disconnect();
|
||||
return true;
|
||||
}
|
||||
didFinish = true
|
||||
if (obs) obs.disconnect()
|
||||
return true
|
||||
}
|
||||
|
||||
function trySyncDebounced() {
|
||||
if (debounceId) return;
|
||||
debounceId = setTimeout(function () {
|
||||
debounceId = null;
|
||||
if (syncOnce() && obs) obs.disconnect();
|
||||
}, 50);
|
||||
}
|
||||
function trySyncDebounced() {
|
||||
if (debounceId) return
|
||||
debounceId = setTimeout(function () {
|
||||
debounceId = null
|
||||
if (syncOnce() && obs) obs.disconnect()
|
||||
}, 50)
|
||||
}
|
||||
|
||||
if (document.readyState === 'loading') {
|
||||
document.addEventListener('DOMContentLoaded', trySyncDebounced, { once: true });
|
||||
} else {
|
||||
trySyncDebounced();
|
||||
}
|
||||
if (document.readyState === 'loading') {
|
||||
document.addEventListener('DOMContentLoaded', trySyncDebounced, {
|
||||
once: true,
|
||||
})
|
||||
} else {
|
||||
trySyncDebounced()
|
||||
}
|
||||
|
||||
obs = new MutationObserver(trySyncDebounced);
|
||||
obs.observe(document.body || document.documentElement, { childList: true, subtree: true });
|
||||
obs = new MutationObserver(trySyncDebounced)
|
||||
obs.observe(document.body || document.documentElement, {
|
||||
childList: true,
|
||||
subtree: true,
|
||||
})
|
||||
|
||||
if (window.prestashop && typeof window.prestashop.on === 'function') {
|
||||
['updateProductList', 'updatedCart', 'updatedProduct'].forEach(function (ev) {
|
||||
window.prestashop.on(ev, trySyncDebounced);
|
||||
});
|
||||
}
|
||||
if (window.prestashop && typeof window.prestashop.on === 'function') {
|
||||
;['updateProductList', 'updatedCart', 'updatedProduct'].forEach(function (
|
||||
ev
|
||||
) {
|
||||
window.prestashop.on(ev, trySyncDebounced)
|
||||
})
|
||||
}
|
||||
|
||||
(function hookHistory() {
|
||||
var _ps = history.pushState, _rs = history.replaceState;
|
||||
function onNav() { trySyncDebounced(); }
|
||||
history.pushState = function () { _ps.apply(this, arguments); onNav(); };
|
||||
history.replaceState = function () { _rs.apply(this, arguments); onNav(); };
|
||||
window.addEventListener('popstate', onNav);
|
||||
})();
|
||||
})();
|
||||
;(function hookHistory() {
|
||||
var _ps = history.pushState,
|
||||
_rs = history.replaceState
|
||||
function onNav() {
|
||||
trySyncDebounced()
|
||||
}
|
||||
history.pushState = function () {
|
||||
_ps.apply(this, arguments)
|
||||
onNav()
|
||||
}
|
||||
history.replaceState = function () {
|
||||
_rs.apply(this, arguments)
|
||||
onNav()
|
||||
}
|
||||
window.addEventListener('popstate', onNav)
|
||||
})()
|
||||
})()
|
||||
|
||||
$(document).ready(function () {
|
||||
function toggleChatWidget(isOpen) {
|
||||
var $widget = $('div[data-testid="widgetButtonFrame"]')
|
||||
var $scrollBox = $('.scroll-brn-box')
|
||||
|
||||
function toggleChatWidget(isOpen) {
|
||||
var $widget = $('div[data-testid="widgetButtonFrame"]');
|
||||
var $scrollBox = $('.scroll-brn-box')
|
||||
if ($widget.length) {
|
||||
if (isOpen) {
|
||||
$widget.hide()
|
||||
$scrollBox.hide()
|
||||
} else {
|
||||
$widget.show()
|
||||
$scrollBox.show()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if ($widget.length) {
|
||||
if (isOpen) {
|
||||
$widget.hide();
|
||||
$scrollBox.hide();
|
||||
} else {
|
||||
$widget.show();
|
||||
$scrollBox.show();
|
||||
}
|
||||
}
|
||||
}
|
||||
function checkCartState() {
|
||||
var $cart = $('.elementor-cart__container')
|
||||
var isOpen = $cart.hasClass('elementor-cart--shown')
|
||||
toggleChatWidget(isOpen)
|
||||
}
|
||||
|
||||
function checkCartState() {
|
||||
var $cart = $('.elementor-cart__container');
|
||||
var isOpen = $cart.hasClass('elementor-cart--shown');
|
||||
toggleChatWidget(isOpen);
|
||||
}
|
||||
$('a[href*="koszyk"][class*="elementor-button"]').on('click', function () {
|
||||
setTimeout(checkCartState, 300)
|
||||
})
|
||||
|
||||
$('a[href*="koszyk"][class*="elementor-button"]').on('click', function () {
|
||||
setTimeout(checkCartState, 300);
|
||||
});
|
||||
$(document).on('click', '.elementor-cart__close-button', function () {
|
||||
setTimeout(checkCartState, 300)
|
||||
})
|
||||
|
||||
$(document).on('click', '.elementor-cart__close-button', function () {
|
||||
setTimeout(checkCartState, 300);
|
||||
});
|
||||
$(document).on(
|
||||
'click',
|
||||
'.elementor-cart__container.elementor-lightbox.elementor-cart--shown',
|
||||
function (e) {
|
||||
if (e.target === this) {
|
||||
setTimeout(checkCartState, 300)
|
||||
}
|
||||
}
|
||||
)
|
||||
|
||||
$(document).on('click', '.elementor-cart__container.elementor-lightbox.elementor-cart--shown', function (e) {
|
||||
if (e.target === this) {
|
||||
setTimeout(checkCartState, 300);
|
||||
}
|
||||
});
|
||||
const cartContainer = document.querySelector('.elementor-cart__container')
|
||||
if (cartContainer) {
|
||||
const observer = new MutationObserver(() => checkCartState())
|
||||
observer.observe(cartContainer, {
|
||||
attributes: true,
|
||||
attributeFilter: ['class'],
|
||||
})
|
||||
}
|
||||
|
||||
const cartContainer = document.querySelector('.elementor-cart__container');
|
||||
if (cartContainer) {
|
||||
const observer = new MutationObserver(() => checkCartState());
|
||||
observer.observe(cartContainer, { attributes: true, attributeFilter: ['class'] });
|
||||
}
|
||||
|
||||
checkCartState();
|
||||
});
|
||||
checkCartState()
|
||||
})
|
||||
|
||||
$(document).ready(function () {
|
||||
if ($('#buy-by-phone-popup').length) {
|
||||
var buyByPhonePopup = $('#buy-by-phone-popup')
|
||||
|
||||
$('#buy_by_phone_btn').on('click', function (e) {
|
||||
$('#buy-by-phone-popup').find('input[name="buy-by-phone-name"]').val('')
|
||||
$('#buy-by-phone-popup').find('input[name="buy-by-phone-phone"]').val('')
|
||||
$('#buy-by-phone-popup').find('input[name="contact-time"]').val('')
|
||||
$('#buy-by-phone-popup').find('input[name="product-name"]').val('')
|
||||
$('#buy-by-phone-popup').find('input[name="shipping-address"]').val('')
|
||||
$('#buy-by-phone-popup').find('input[name="phone-for-courier"]').val('')
|
||||
$('#buy-by-phone-popup').find('input[name="email"]').val('')
|
||||
$('#buy-by-phone-popup').find('input[name="comments-to-order"]').val('')
|
||||
$('#buy-by-phone-popup .popup-footer').empty()
|
||||
$('#buy-by-phone-popup')
|
||||
.find('input[name="polityka"]')
|
||||
.prop('checked', false)
|
||||
|
||||
buyByPhonePopup.addClass('active')
|
||||
})
|
||||
|
||||
$('.close-popup', buyByPhonePopup).on('click', function (e) {
|
||||
e.preventDefault()
|
||||
buyByPhonePopup.removeClass('active')
|
||||
})
|
||||
$('.close-popup-alert', buyByPhonePopup).on('click', function (e) {
|
||||
e.preventDefault()
|
||||
$('.popup-alert', buyByPhonePopup).removeClass('active')
|
||||
})
|
||||
|
||||
$('#buy-by-phone-form-btn').on('click', function (e) {
|
||||
e.preventDefault()
|
||||
|
||||
$('#buy-by-phone-popup .popup-footer').empty()
|
||||
|
||||
var name = $('#buy-by-phone-popup')
|
||||
.find('input[name="buy-by-phone-name"]')
|
||||
.val()
|
||||
var phone = $('#buy-by-phone-popup')
|
||||
.find('input[name="buy-by-phone-phone"]')
|
||||
.val()
|
||||
var contact_time = $('#buy-by-phone-popup')
|
||||
.find('input[name="contact-time"]')
|
||||
.val()
|
||||
var politics = $('#buy-by-phone-popup')
|
||||
.find('input[name="polityka"]')
|
||||
.prop('checked')
|
||||
|
||||
if (!phone) {
|
||||
popupAlert('<p>Proszę wypełnić wymagane pola formularza</p>')
|
||||
return
|
||||
}
|
||||
if (!politics) {
|
||||
popupAlert('<p>Proszę wypełnić wymagane pola formularza</p>')
|
||||
return
|
||||
}
|
||||
|
||||
$(this).prop('disabled', true)
|
||||
|
||||
var formData = $('#buy-by-phone-form').serialize()
|
||||
|
||||
$.ajax({
|
||||
type: 'POST',
|
||||
url: '/buy-by-phone.php',
|
||||
data: formData,
|
||||
success: function (response) {
|
||||
popupAlert(response)
|
||||
$('#buy-by-phone-form-btn').prop('disabled', false)
|
||||
setTimeout(function () {
|
||||
buyByPhonePopup.removeClass('active')
|
||||
}, 5000)
|
||||
},
|
||||
error: function () {
|
||||
popupAlert('<p>Wystąpił błąd podczas wysyłania danych</p>')
|
||||
$('#buy-by-phone-form-btn').prop('disabled', false)
|
||||
},
|
||||
})
|
||||
})
|
||||
|
||||
function popupAlert(text) {
|
||||
$('.popup-alert', buyByPhonePopup).addClass('active')
|
||||
$('.popup-alert .popup-alert-data', buyByPhonePopup).empty()
|
||||
$('.popup-alert .popup-alert-data', buyByPhonePopup).append(text)
|
||||
setTimeout(function () {
|
||||
$('.popup-alert', buyByPhonePopup).removeClass('active')
|
||||
}, 3000)
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
@@ -0,0 +1,102 @@
|
||||
<div id="buy-by-phone-popup">
|
||||
<div class="buy-by-phone-popup--wrapper">
|
||||
<div class="popup-header">
|
||||
<div class="popup-header--close">
|
||||
<a href="#" title="close" class="close-popup">
|
||||
<i class="fa fa-times" aria-hidden="true"></i>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="popup-body">
|
||||
<div class="popup-body--left">
|
||||
<div class="popup-img">
|
||||
<img class="product-cover" src="{$product.cover.bySize.large_default.url}" alt="{$product.cover.legend}"
|
||||
title="{$product.cover.legend}" itemprop="image">
|
||||
</div>
|
||||
</div>
|
||||
<div class="popup-body--right">
|
||||
<div class="popup-body-top">
|
||||
<p>ZADZWOŃ <a href="tel:172000035">172000035</a> lub uzupełnij i wyślij poniższy formularz, wówczas to my skontaktujemy się z Tobą.</p>
|
||||
<form id="buy-by-phone-form" action="/buy-by-phone.php" method="post">
|
||||
<input type="hidden" name="buy-by-phone-mail-from" value="masimmo">
|
||||
<input type="hidden" name="buy-by-phone-product-name" value="{$product.name}">
|
||||
<input type="hidden" name="buy-by-phone-product-uri" value="{$product.link}">
|
||||
<div class="form-cols">
|
||||
<div class="form-group lql-form-content-element">
|
||||
<input type="text" class="form-control form-control-name" name="buy-by-phone-name" placeholder="Twoje imię">
|
||||
</div>
|
||||
<div class="form-group lql-form-content-element">
|
||||
<input type="text" class="form-control form-control-phone" name="buy-by-phone-phone" required="required" placeholder="Numer telefonu *">
|
||||
</div>
|
||||
</div>
|
||||
<span class="popup-input-alert">* pole jest wymagane</span>
|
||||
<br/><br/>
|
||||
<p>Potrzebuję porady odnośnie doboru produktu:</p>
|
||||
<div class="form-group lql-form-content-element form-group-radio">
|
||||
<label class="radio-inline">
|
||||
<input type="radio" name="buy-by-phone-need-advice" value="tak"> Tak
|
||||
</label>
|
||||
<label class="radio-inline">
|
||||
<input type="radio" name="buy-by-phone-need-advice" value="nie"> Nie
|
||||
</label>
|
||||
</div>
|
||||
|
||||
<div class="form-group lql-form-content-element">
|
||||
<input type="text" class="form-control" name="contact-time" placeholder="Preferowana data/godzina kontaktu">
|
||||
</div>
|
||||
|
||||
<div class="form-group lql-form-content-element">
|
||||
<input type="text" class="form-control" name="product-to-buy" placeholder="Produkt jaki chcę kupić">
|
||||
</div>
|
||||
<div class="form-group lql-form-content-element">
|
||||
<input type="text" class="form-control" name="shipping-address" placeholder="Adres do wysyłki">
|
||||
</div>
|
||||
<div class="form-group lql-form-content-element">
|
||||
<input type="text" class="form-control" name="phone-for-courier"
|
||||
placeholder="Numer telefonu dla kuriera">
|
||||
</div>
|
||||
<div class="form-group lql-form-content-element">
|
||||
<input type="text" class="form-control" name="email" placeholder="Adres e-mail">
|
||||
</div>
|
||||
<div class="form-group lql-form-content-element">
|
||||
<input type="text" class="form-control" name="comments-to-order" placeholder="Uwagi do zamówienia">
|
||||
</div>
|
||||
|
||||
<div class="form-group lql-form-content-element form-group-polityka">
|
||||
<input type="checkbox" class="form-control" name="polityka" id="polityka" required="">
|
||||
<label for="polityka">
|
||||
* Wyrażam zgodę na przetwarzanie przez Dr Materac sp. z o.o. mojego adresu e-mail oraz innych danych osobowych, które dobrowolnie podaję w treści wiadomości w celu udzielenia na nią odpowiedzi i kontaktu. Zapoznałem się z <a href="/content/92-regulamin-sprzedazy-telefonicznej" target="_blank">Regulaminem</a> i <a href="/content/12-polityka-prywatnosci" target="_blank">Polityką prywatności</a>
|
||||
</label>
|
||||
</div>
|
||||
|
||||
<br/>
|
||||
<div class="g-recaptcha" data-sitekey="6LeJAUUsAAAAAB9l4SYYqmjAS6RwHwoyfUgTJQ5e"></div>
|
||||
<br/>
|
||||
|
||||
<button type="submit" class="form-control-submit lql-form-bt lql-register-bt btn btn-primary"
|
||||
id="buy-by-phone-form-btn">
|
||||
<span class="lql-bt-txt">
|
||||
Wyślij
|
||||
</span>
|
||||
</button>
|
||||
</form>
|
||||
</div>
|
||||
<div class="popup-alert">
|
||||
<div class="popup-alert-wrapper">
|
||||
<div class="popup-alert-close">
|
||||
<a href="#" title="close" class="close-popup-alert">
|
||||
<i class="fa fa-times" aria-hidden="true"></i>
|
||||
</a>
|
||||
</div>
|
||||
<div class="popup-alert-data">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{literal}
|
||||
<script src="https://www.google.com/recaptcha/api.js" async defer></script>
|
||||
{/literal}
|
||||
@@ -65,6 +65,19 @@
|
||||
</div>
|
||||
{/block}
|
||||
|
||||
|
||||
{block name='product_buy_by_phone'}
|
||||
{if $product_manufacturer->id == 3}
|
||||
<div class="buy_by_phone" id="buy_by_phone_btn">
|
||||
<button class="btn btn-primary add-to-cart" {if !$product.add_to_cart_url} disabled {/if}>
|
||||
{l s='Buy by phone' d='Shop.Theme.Actions'}
|
||||
</button>
|
||||
</div>
|
||||
|
||||
{include file='catalog/_partials/buy-by-phone-popup.tpl' product=$product}
|
||||
{/if}
|
||||
{/block}
|
||||
|
||||
{block name='product_availability'}
|
||||
<span id="product-availability" class="js-product-availability">
|
||||
{if $product.show_availability && $product.availability_message}
|
||||
|
||||
Reference in New Issue
Block a user