111 lines
4.3 KiB
HTML
111 lines
4.3 KiB
HTML
<table class="form-table">
|
|
<tr>
|
|
<th scope="row">
|
|
<label for="settings[woocommerce_optin_on_checkout]">
|
|
<%= _x('Opt-in on checkout', "settings area: add an email opt-in checkbox on the checkout page (e-commerce websites)") %>
|
|
</label>
|
|
<p class="description">
|
|
<%= __('Customers can subscribe to the "WooCommerce Customers" list via a checkbox on the checkout page.') %>
|
|
</p>
|
|
</th>
|
|
<td>
|
|
<p>
|
|
<input
|
|
data-toggle="mailpoet_woocommerce_optin_on_checkout"
|
|
type="checkbox"
|
|
value="1"
|
|
id="settings[woocommerce_optin_on_checkout]"
|
|
name="woocommerce[optin_on_checkout][enabled]"
|
|
<% if(settings.woocommerce.optin_on_checkout.enabled) %>checked="checked"<% endif %>
|
|
>
|
|
</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="mailpoet_woocommerce_optin_on_checkout">
|
|
<th scope="row">
|
|
<label for="settings[woocommerce_checkbox_optin_message]">
|
|
<%= _x('Checkbox opt-in message', "settings area: set the email opt-in message on the checkout page (e-commerce websites)") %>
|
|
</label>
|
|
<p class="description">
|
|
<%= __('This is the checkbox message your customers will see on your WooCommerce checkout page to subscribe to the "WooCommerce Customers" list.') %>
|
|
</p>
|
|
</th>
|
|
<td>
|
|
<p>
|
|
<input type="text"
|
|
id="woocommerce_checkbox_optin_message"
|
|
name="woocommerce[optin_on_checkout][message]"
|
|
value="<%= settings.woocommerce.optin_on_checkout.message %>"
|
|
placeholder="<%= _x('Checkbox opt-in message', "placeholder text for the WooCommerce checkout opt-in message") %>"
|
|
class="regular-text" />
|
|
<br>
|
|
<div id="settings_woocommerce_optin_on_checkout_error" class="mailpoet_error_item mailpoet_error">
|
|
<%= __('The checkbox opt-in message cannot be empty.') %>
|
|
</div>
|
|
</p>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<th scope="row">
|
|
<label for="settings[mailpoet_subscribe_old_woocommerce_customers]">
|
|
<%= __('Subscribe old WooCommerce customers') %>
|
|
</label>
|
|
<p class="description">
|
|
<%= __('Subscribe all my past customers to this list because they agreed to receive marketing emails from me.') %>
|
|
</p>
|
|
</th>
|
|
<td>
|
|
<p>
|
|
<input
|
|
type="checkbox"
|
|
value="1"
|
|
id="settings[mailpoet_subscribe_old_woocommerce_customers]"
|
|
name="mailpoet_subscribe_old_woocommerce_customers[enabled]"
|
|
<% if(settings.mailpoet_subscribe_old_woocommerce_customers.enabled) %>checked="checked"<% endif %>
|
|
>
|
|
<#
|
|
Our settings is stupid:
|
|
We cannot use a simple checkbox with a simple name. The name must be an array.
|
|
We are using `$.serializeArray` and that ignores empty values.
|
|
So if the checkbox is not checked it is not sent to the server and not saved.
|
|
|
|
For that reason we need the hidden field which is always sent to server and if the checkbox
|
|
is not set it will rewrite the array in the database using only the dummy field.
|
|
#>
|
|
<input
|
|
type="hidden"
|
|
value="1"
|
|
name="mailpoet_subscribe_old_woocommerce_customers[dummy]"
|
|
>
|
|
</p>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<th scope="row">
|
|
<label for="settings[mailpoet_accept_cookie_revenue_tracking]">
|
|
<%= _x('Enable browser cookies', 'Option in settings page: the user can accept or forbid MailPoet to use browser cookies') %>
|
|
</label>
|
|
<p class="description">
|
|
<%= _x('If you enable this option, MailPoet will use browser cookies for more precise WooCommerce tracking. This is practical for abandoned cart emails for example.', 'Browser cookies are data created by websites and stored in visitors web browser') %>
|
|
</p>
|
|
</th>
|
|
<td>
|
|
<p>
|
|
<input
|
|
type="checkbox"
|
|
value="1"
|
|
id="settings[mailpoet_accept_cookie_revenue_tracking]"
|
|
data-automation-id="accept_cookie_revenue_tracking"
|
|
name="woocommerce[accept_cookie_revenue_tracking][enabled]"
|
|
<% if(settings.woocommerce.accept_cookie_revenue_tracking.enabled == "1") %>checked="checked"<% endif %>
|
|
>
|
|
<input
|
|
type="hidden"
|
|
value="1"
|
|
name="woocommerce[accept_cookie_revenue_tracking][set]"
|
|
>
|
|
</p>
|
|
</td>
|
|
</tr>
|
|
</table>
|