Добрый день!
Ребята!! Очень нужна помощь в написании стороннего кода на сайт для подписания на рассылку. Прежде стоял код, девушка писала его вручную, но там что-то сбилось и сайт начал выдавать ошибку при подписке.
Unisender сказал, что ошибка в этом друге... И еще нужно вставить API..
Надеюсь, я корректно описала проблему. Буду безумно благодарна за помощь или наставление)
имеющийся код вот:
<link href="https://cp.unisender.com/v5/template-editor-new/js/lib/datepicker/pikaday.css" rel="stylesheet" type="text/css" /><script type="text/javascript" src="https://cp.unisender.com/v5/template-editor-new/js/lib/moment/moment-with-langs.min.js"></script><script type="text/javascript" src="https://cp.unisender.com/v5/template-editor-new/js/lib/datepicker/pikaday.js"></script><script type="text/javascript" src="https://cp.unisender.com/v5/template-editor-new/js/app/lang/ru.js"></script><script type="text/javascript" src="https://cp.unisender.com/v5/template-editor-new/js/app/preview/form/form-js.js"></script>
<form action="https://cp.unisender.com/ru/subscribe?hash=6o5g6sszq3n9ok1xkmp5q76chtyjsn1atucp544c3ao3e8pf8xrdy" method="POST" name="subscribtion_form" us_mode="embed">
<div class="container responsive">
<p style="text-align: center;"> </p>
<p style="text-align: center;"> </p>
<p style="text-align: center;">УЗНАВАЙТЕ О НОВОСТЯХ И НОВИНКАХ ПЕРВЫМИ!</p>
<link type="text/css" rel="stylesheet" href="https://cp.unisender.com/v5/template-editor-new/js/lib/datepicker/pikaday.css"/><script type="text/javascript" src="https://cp.unisender.com/v5/template-editor-new/js/lib/moment/moment-with-langs.min.js"></script><script type="text/javascript" src="https://cp.unisender.com/v5/template-editor-new/js/lib/datepicker/pikaday.js"></script><script type="text/javascript" src="https://cp.unisender.com/v5/template-editor-new/js/app/lang/ru.js"></script><script type="text/javascript" src="https://cp.unisender.com/v5/template-editor-new/js/app/preview/form/form-js.js"></script><form method="POST" action="https://cp.unisender.com/ru/subscribe?hash=6o5g6sszq3n9ok1xkmp5q76chtyjsn1atucp544c3ao3e8pf8xrdy" name="subscribtion_form" us_mode="embed"><div class="container responsive"><table cellpadding="0" cellspacing="0" align="center" style="width: 100%; box-sizing: border-box; background-color: rgb(255, 255, 255); float: left;"><tbody><tr><td><!--[if (gte mso 9)|(IE)]><table cellpadding="0" cellspacing="0" border="0" width="400" align="center"><tr><td><![endif]--><table cellpadding="0" cellspacing="0" align="center" style="background-color: rgb(255, 255, 255); border-top-left-radius: 0px; border-top-right-radius: 0px; border-bottom-right-radius: 0px; border-bottom-left-radius: 0px; max-width: 450px; width: 100%; border: none; margin: 0px auto; border-spacing: 0px; border-collapse: collapse;"><tbody><tr><td width="100%" style="vertical-align: top; max-width: 450px; font-size: 0px; padding: 25px;"><!--[if (gte mso 9)|(IE)]><table cellpadding="0" cellspacing="0" border="0" width="400" align="center"><tr><td><![endif]--> <table width="100%" border="0" cellspacing="0" cellpadding="0" style="width: 100%; table-layout: fixed; height: auto; border-collapse: collapse; border-spacing: 0px; display: inline-table; vertical-align: top; font-size: medium;"> <tbody><tr> <td style="width: 100%; padding: 8px; height: 41px;" valign="top"> <table border="0" cellspacing="0" cellpadding="0" style="height: 100%; width: 100%; table-layout: fixed; border-spacing: 0px; border-collapse: collapse; min-height: 41px;"> <tbody><tr> <td style="width: 100%; font-family: Verdana, Geneva, sans-serif; font-size: 12px; color: rgb(34, 34, 34);"> <div style="display:inline-block; width:100%;font-size:0;"> <label style="font-size: 12px; padding: 0px 0px 5px; vertical-align: middle; box-sizing: border-box; width: 14%; display: inline-block; font-family: Verdana, Geneva, sans-serif; color: rgb(34, 34, 34);"> <span></span> </b> </label> <div style="display: inline-block; width: 70%;"> <input type="text" name="email" _validator="email" _required="1" style="border-top-left-radius: 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px; font-style: normal; font-variant-caps: normal; font-weight: normal; font-size: 13px; line-height: 1; font-family: Arial, Helvetica; padding: 0px 8px; width: 100%; box-sizing: border-box; border-image-source: none; border-width: 0px 0px 1px; border-style: solid; border-color: rgb(193, 201, 203); background-color: rgb(255, 255, 255); background-image: none; height: 25px;" _label="" placeholder="укажите e-mail"> <div class="error-block" style="display:none;color:#ff592d;font:11px/18px Arial;"></div> </div> </div> </td> </tr> </tbody></table> </td> </tr> </tbody></table> <!--[if (gte mso 9)|(IE)]></td></tr></table><![endif]--><!--[if (gte mso 9)|(IE)]><table cellpadding="0" cellspacing="0" border="0" width="400" align="center"><tr><td><![endif]--> <table width="100%" border="0" cellspacing="0" cellpadding="0" style="width: 100%; table-layout: fixed; height: auto; border-collapse: collapse; border-spacing: 0px; display: inline-table; vertical-align: top; font-size: medium;"> <tbody><tr> <td style="width: 100%; background-image: none; min-height: 30px; height: 30px;" valign="top"> <table border="0" cellspacing="0" cellpadding="0" style="height: 100%; width: 100%; table-layout: fixed; border-spacing: 0px; border-collapse: collapse; min-height: 30px;"> <tbody><tr> <td style="width: 100%; text-align: center; font-family: Verdana, Geneva, sans-serif; font-size: 12px; color: rgb(34, 34, 34);"> <table border="0" cellpadding="0" cellspacing="0" width="100%" style="display: inline-table; width: auto; border-spacing: 0px; border-collapse: collapse;"> <tbody><tr> <td align="center" valign="middle" style="border-top-left-radius: 0px; border-top-right-radius: 0px; border-bottom-right-radius: 0px; border-bottom-left-radius: 0px; border: none; padding: 5px; background-color: rgb(234, 234, 234); height: 20px; min-height: 20px;"> <button href="javascript:" target="_blank" style="width: 100%; display: inline-block; text-decoration: none; word-break: break-all; font-size: 11px; font-family: Verdana, Geneva, sans-serif; line-height: 13.2px; color: rgb(77, 76, 77); background-color: rgb(234, 234, 234); border: 0px;">Подписаться</button> </td> </tr> </tbody></table> </td> </tr> </tbody></table> </td> </tr> </tbody></table> <!--[if (gte mso 9)|(IE)]></td></tr></table><![endif]--></td></tr></tbody></table><!--[if (gte mso 9)|(IE)]></td></tr></table><![endif]--></td></tr></tbody></table></div><input type="hidden" name="charset" value="UTF-8">
<input type="hidden" name="default_list_id" value="9118651">
<input type="hidden" name="overwrite" value="2">
<input type="hidden" name="is_v5" value="1"></form>
<script type="text/javascript">
$(document).ready(function() {
// добавление в корзину
$("#skuadd[data-default='Добавить в корзину']").on('click', function() {
yaCounter43619569.reachGoal(`cart-order`);
ga(`send`,`event`,`Put`,`cart-order`);
});
// добавление в корзину
$(".shop-add-to-cart-catalog-btn").on('click', function() {
yaCounter43619569.reachGoal(`cart-order`);
ga(`send`,`event`,`Put`,`cart-order`);
});
// страница заказа
$('.shop-cart-order-form .form__btn.progress-button').click(function() {
error = false;
$('.shop-cart-order-form .form__field_field[data-required="y"]').each(function() {
if ($(this).val() == "") {
error = true;
}
if($(this).closest('.error-input').length > 0) {
error = true;
}
});
if (!error) {
yaCounter43619569.reachGoal(`buy-order`);
ga(`send`,`event`,`Put`,`buy-order`);
}
});
});
</script>