Merge branch 'develop' of gitlab.antadis.net:dev-antadis/toutpratique into develop
This commit is contained in:
commit
14cd8559d1
@ -32,7 +32,7 @@ class AuthController extends AuthControllerCore
|
||||
$this->errors[] = Tools::displayError('An email address required.');
|
||||
} elseif (!Validate::isEmail($email)) {
|
||||
$this->errors[] = Tools::displayError('Invalid email address.');
|
||||
} elseif (!preg_match('/^(?!(?:(?:\x22?\x5C[\x00-\x7E]\x22?)|(?:\x22?[^\x5C\x22]\x22?)){255,})(?!(?:(?:\x22?\x5C[\x00-\x7E]\x22?)|(?:\x22?[^\x5C\x22]\x22?)){65,}@)(?:(?:[\x21\x23-\x27\x2A\x2B\x2D\x2F-\x39\x3D\x3F\x5E-\x7E]+)|(?:\x22(?:[\x01-\x08\x0B\x0C\x0E-\x1F\x21\x23-\x5B\x5D-\x7F]|(?:\x5C[\x00-\x7F]))*\x22))(?:\.(?:(?:[\x21\x23-\x27\x2A\x2B\x2D\x2F-\x39\x3D\x3F\x5E-\x7E]+)|(?:\x22(?:[\x01-\x08\x0B\x0C\x0E-\x1F\x21\x23-\x5B\x5D-\x7F]|(?:\x5C[\x00-\x7F]))*\x22)))*@(?:(?:(?!.*[^.]{64,})(?:(?:(?:xn--)?[a-z0-9]+(?:-[a-z0-9]+)*\.){1,126}){1,}(?:(?:[a-z][a-z0-9]*)|(?:(?:xn--)[a-z0-9]+))(?:-[a-z0-9]+)*)|(?:\[(?:(?:IPv6:(?:(?:[a-f0-9]{1,4}(?::[a-f0-9]{1,4}){7})|(?:(?!(?:.*[a-f0-9][:\]]){7,})(?:[a-f0-9]{1,4}(?::[a-f0-9]{1,4}){0,5})?::(?:[a-f0-9]{1,4}(?::[a-f0-9]{1,4}){0,5})?)))|(?:(?:IPv6:(?:(?:[a-f0-9]{1,4}(?::[a-f0-9]{1,4}){5}:)|(?:(?!(?:.*[a-f0-9]:){5,})(?:[a-f0-9]{1,4}(?::[a-f0-9]{1,4}){0,3})?::(?:[a-f0-9]{1,4}(?::[a-f0-9]{1,4}){0,3}:)?)))?(?:(?:25[0-5])|(?:2[0-4][0-9])|(?:1[0-9]{2})|(?:[1-9]?[0-9]))(?:\.(?:(?:25[0-5])|(?:2[0-4][0-9])|(?:1[0-9]{2})|(?:[1-9]?[0-9]))){3}))\]))$/iD', $email)) {
|
||||
} elseif (!preg_match('/^(?=[A-Z0-9][A-Z0-9@._%+-]{5,253}+$)[A-Z0-9._%+-]{1,64}+@(?:(?=[A-Z0-9-]{1,63}+\.)[A-Z0-9]++(?:-[A-Z0-9]++)*+\.){1,8}+[A-Z]{2,63}+$/i', $email)) {
|
||||
$this->errors[] = Tools::displayError('Invalid email address.');
|
||||
} elseif (Customer::customerExists($email)) {
|
||||
$this->errors[] = Tools::displayError('An account using this email address has already been registered.', false);
|
||||
|
@ -19,7 +19,9 @@ class BlockNewsletterOverride extends BlockNewsletter
|
||||
|
||||
public function ajaxCall($email, $action = 0, $page, $id_post = false)
|
||||
{
|
||||
if (empty($email) || !Validate::isEmail($email)) {
|
||||
if (empty($email)
|
||||
|| !preg_match('/^(?=[A-Z0-9][A-Z0-9@._%+-]{5,253}+$)[A-Z0-9._%+-]{1,64}+@(?:(?=[A-Z0-9-]{1,63}+\.)[A-Z0-9]++(?:-[A-Z0-9]++)*+\.){1,8}+[A-Z]{2,63}+$/i', $email)
|
||||
|| !Validate::isEmail($email)) {
|
||||
return array(
|
||||
'has_error' => true,
|
||||
'css' => 'alert alert-danger',
|
||||
@ -90,7 +92,9 @@ class BlockNewsletterOverride extends BlockNewsletter
|
||||
*/
|
||||
protected function newsletterRegistration()
|
||||
{
|
||||
if (empty($_POST['email']) || !Validate::isEmail($_POST['email'])) {
|
||||
if (empty($_POST['email'])
|
||||
|| !preg_match('/^(?=[A-Z0-9][A-Z0-9@._%+-]{5,253}+$)[A-Z0-9._%+-]{1,64}+@(?:(?=[A-Z0-9-]{1,63}+\.)[A-Z0-9]++(?:-[A-Z0-9]++)*+\.){1,8}+[A-Z]{2,63}+$/i', $_POST['email'])
|
||||
|| !Validate::isEmail($_POST['email'])) {
|
||||
return $this->error = $this->l('Invalid email address.');
|
||||
} else if ($_POST['action'] == '1') {
|
||||
/* Unsubscription */
|
||||
|
@ -59,7 +59,7 @@
|
||||
{if isset($column)}
|
||||
<h2 class="product-name" itemprop="name">
|
||||
{else}
|
||||
<h5 class="product-name" itemprop="name">
|
||||
<h2 class="product-name" itemprop="name">
|
||||
{/if}
|
||||
<a href="{$product.link|escape:'html':'UTF-8'}" title="{$product.name|escape:'html':'UTF-8'}" itemprop="url" >
|
||||
{if !isset($column)}
|
||||
@ -71,7 +71,7 @@
|
||||
{if isset($column)}
|
||||
</h2>
|
||||
{else}
|
||||
</h5>
|
||||
</h2>
|
||||
{/if}
|
||||
<div class="featureConditioning">
|
||||
{foreach from=$product.features item='feature' name='feature'}
|
||||
|
@ -476,9 +476,6 @@
|
||||
</div>
|
||||
<div class="col-md-9 content_pack">
|
||||
{$packItem.pack_quantity} x <a class="link" href="{$link->getProductLink($packItem.id_product, $packItem.link_rewrite, $packItem.category)|escape:'html':'UTF-8'}">{$packItem.name|escape:'html':'UTF-8'}</a>
|
||||
<p class="price">
|
||||
{l s='Prix unitaire :'} <span class="red">{convertPrice price=$packItem.price}</span>
|
||||
</p>
|
||||
|
||||
<!-- <h5>{l s='Data sheet'}</h5> -->
|
||||
<ul class="features">
|
||||
|
Loading…
Reference in New Issue
Block a user