Facebook currency
This commit is contained in:
parent
233faf8026
commit
cd7483274d
@ -16,19 +16,11 @@ class OrderConfirmationController extends OrderConfirmationControllerCore
|
||||
$productIds[] = (int) $product['product_id'];
|
||||
}
|
||||
|
||||
$currency = Currency::getCurrency((int) $order->id_currency);
|
||||
$currencyIsoCode = 'EUR';
|
||||
if (!empty($currency['iso_code'])) {
|
||||
$currencyIsoCode = $currency['iso_code'];
|
||||
}
|
||||
|
||||
self::$smarty->assign(
|
||||
array(
|
||||
'order' => $order,
|
||||
'productIds' => $productIds,
|
||||
'currency' => $currencyIsoCode,
|
||||
)
|
||||
);
|
||||
self::$smarty->assign(array(
|
||||
'order' => $order,
|
||||
'productIds' => $productIds,
|
||||
'currency' => Currency::getCurrency((int) $order->id_currency),
|
||||
));
|
||||
}
|
||||
|
||||
public function displayContent()
|
||||
|
@ -27,416 +27,451 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:fb="http://ogp.me/ns/fb#" xml:lang="{$lang_iso}">
|
||||
<head>
|
||||
<title>{$meta_title|escape:'htmlall':'UTF-8'}</title>
|
||||
{if isset($meta_description) AND $meta_description}
|
||||
<meta name="description" content="{$meta_description|escape:html:'UTF-8'}" />
|
||||
{/if}
|
||||
{if isset($meta_keywords) AND $meta_keywords}
|
||||
<meta name="keywords" content="{$meta_keywords|escape:html:'UTF-8'}" />
|
||||
{/if}
|
||||
{if isset($meta_fb_img) AND $meta_fb_img}
|
||||
<meta property="og:image" content="{$meta_fb_img|escape:html:'UTF-8'}" />
|
||||
{/if}
|
||||
<meta http-equiv="Content-Type" content="application/xhtml+xml; charset=utf-8" />
|
||||
<meta name="robots" content="{if isset($nobots)}no{/if}index,follow" />
|
||||
<link rel="icon" type="image/png" href="{$img_ps_dir}preview.png?{$img_update_time}" />
|
||||
<link rel="icon" type="image/vnd.microsoft.icon" href="{$img_ps_dir}favicon.ico?{$img_update_time}" />
|
||||
<link rel="shortcut icon" type="image/x-icon" href="{$img_ps_dir}favicon.ico?{$img_update_time}" />
|
||||
{if isset($page_name) && $page_name == 'authentication'}
|
||||
<link rel="canonical" href="{$link->getPageLink('authentication.php', TRUE)}" />
|
||||
{/if}
|
||||
<script type="text/javascript">
|
||||
var baseDirSsl = '{$base_dir_ssl}';
|
||||
var baseDir = '{$content_dir}';
|
||||
var static_token = '{$static_token}';
|
||||
var token = '{$token}';
|
||||
var priceDisplayPrecision = {$priceDisplayPrecision*$currency->decimals};
|
||||
var priceDisplayMethod = {$priceDisplay};
|
||||
var roundMode = {$roundMode};
|
||||
var isoLang = "{$lang_iso}";
|
||||
</script>
|
||||
{if isset($css_files)}
|
||||
<title>{$meta_title|escape:'htmlall':'UTF-8'}</title>
|
||||
{if isset($meta_description) AND $meta_description}
|
||||
<meta name="description" content="{$meta_description|escape:html:'UTF-8'}" />
|
||||
{/if}
|
||||
{if isset($meta_keywords) AND $meta_keywords}
|
||||
<meta name="keywords" content="{$meta_keywords|escape:html:'UTF-8'}" />
|
||||
{/if}
|
||||
{if isset($meta_fb_img) AND $meta_fb_img}
|
||||
<meta property="og:image" content="{$meta_fb_img|escape:html:'UTF-8'}" />
|
||||
{/if}
|
||||
|
||||
<meta http-equiv="Content-Type" content="application/xhtml+xml; charset=utf-8" />
|
||||
<meta name="robots" content="{if isset($nobots)}no{/if}index,follow" />
|
||||
<link rel="icon" type="image/png" href="{$img_ps_dir}preview.png?{$img_update_time}" />
|
||||
<link rel="icon" type="image/vnd.microsoft.icon" href="{$img_ps_dir}favicon.ico?{$img_update_time}" />
|
||||
<link rel="shortcut icon" type="image/x-icon" href="{$img_ps_dir}favicon.ico?{$img_update_time}" />
|
||||
{if isset($page_name) && $page_name == 'authentication'}
|
||||
<link rel="canonical" href="{$link->getPageLink('authentication.php', TRUE)}" />
|
||||
{/if}
|
||||
<script type="text/javascript">
|
||||
var baseDirSsl = '{$base_dir_ssl}';
|
||||
var baseDir = '{$content_dir}';
|
||||
var static_token = '{$static_token}';
|
||||
var token = '{$token}';
|
||||
var priceDisplayPrecision = {$priceDisplayPrecision*$currency->decimals};
|
||||
var priceDisplayMethod = {$priceDisplay};
|
||||
var roundMode = {$roundMode};
|
||||
var isoLang = "{$lang_iso}";
|
||||
</script>
|
||||
{if isset($css_files)}
|
||||
{foreach from=$css_files key=css_uri item=media}
|
||||
<link href="{$css_uri}" rel="stylesheet" type="text/css" media="{$media}" />
|
||||
{/foreach}
|
||||
{/if}
|
||||
{if isset($js_files)}
|
||||
{/if}
|
||||
{if isset($js_files)}
|
||||
{foreach from=$js_files item=js_uri}
|
||||
<script type="text/javascript" src="{$js_uri}"></script>
|
||||
{/foreach}
|
||||
{/if}
|
||||
<link rel="apple-touch-icon" href="{$base_dir_ssl}img/apple-touch-icon.png" />
|
||||
{$HOOK_HEADER}
|
||||
<!--[if IE 7]>
|
||||
<link href="{$css_dir}ie7.css" rel="stylesheet" type="text/css" media="screen" />
|
||||
<![endif]-->
|
||||
<!--[if IE 8]>
|
||||
<link href="{$css_dir}ie8.css" rel="stylesheet" type="text/css" media="screen" />
|
||||
<![endif]-->
|
||||
<!--[if IE 9]>
|
||||
<link href="{$css_dir}ie9.css" rel="stylesheet" type="text/css" media="screen" />
|
||||
<![endif]-->
|
||||
{/if}
|
||||
<link rel="apple-touch-icon" href="{$base_dir_ssl}img/apple-touch-icon.png" />
|
||||
{$HOOK_HEADER}
|
||||
<!--[if IE 7]>
|
||||
<link href="{$css_dir}ie7.css" rel="stylesheet" type="text/css" media="screen" />
|
||||
<![endif]-->
|
||||
<!--[if IE 8]>
|
||||
<link href="{$css_dir}ie8.css" rel="stylesheet" type="text/css" media="screen" />
|
||||
<![endif]-->
|
||||
<!--[if IE 9]>
|
||||
<link href="{$css_dir}ie9.css" rel="stylesheet" type="text/css" media="screen" />
|
||||
<![endif]-->
|
||||
|
||||
<!-- Google Tag Manager -->
|
||||
{literal}
|
||||
<script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':
|
||||
new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],
|
||||
j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=
|
||||
'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);
|
||||
})(window,document,'script','dataLayer','GTM-PT7ZGQF');</script>
|
||||
{/literal}
|
||||
<!-- End Google Tag Manager -->
|
||||
<!-- Google Tag Manager -->
|
||||
{literal}
|
||||
<script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':
|
||||
new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],
|
||||
j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=
|
||||
'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);
|
||||
})(window,document,'script','dataLayer','GTM-PT7ZGQF');</script>
|
||||
{/literal}
|
||||
<!-- End Google Tag Manager -->
|
||||
|
||||
{assign var='isEC' value=Configuration::get('GANALYTICS_EC')}
|
||||
{if $cookie->id_lang == 2}
|
||||
{literal}
|
||||
<script>
|
||||
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
|
||||
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
|
||||
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
|
||||
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
|
||||
{assign var='isEC' value=Configuration::get('GANALYTICS_EC')}
|
||||
{if $cookie->id_lang == 2}
|
||||
{literal}
|
||||
<script>
|
||||
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
|
||||
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
|
||||
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
|
||||
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
|
||||
|
||||
ga('create', 'UA-30665119-1', 'auto');
|
||||
ga('create', 'UA-30665119-1', 'auto');
|
||||
{/literal}
|
||||
{if isset($page_name) && $page_name == 'category'}
|
||||
{literal}
|
||||
ga('require', 'ec');
|
||||
|
||||
{/literal}{if isset($page_name) && $page_name == 'category'}{literal}
|
||||
ga('require', 'ec');
|
||||
{/literal}
|
||||
{else if isset($page_name) && $page_name == 'product'}
|
||||
{literal}
|
||||
ga('require', 'ec');
|
||||
ga('ec:addProduct', {
|
||||
'id': {/literal}{$product->id}{literal},
|
||||
'name': "{/literal}{$product->name|escape:'htmlall':'UTF-8'}{literal}",
|
||||
'category': "{/literal}{$sale->title[$cookie->id_lang]}{literal}"
|
||||
});
|
||||
|
||||
ga('ec:setAction', 'detail');
|
||||
|
||||
{/literal}{else if isset($page_name) && $page_name == 'product'}{literal}
|
||||
ga('require', 'ec');
|
||||
ga('ec:addProduct', {
|
||||
'id': {/literal}{$product->id}{literal},
|
||||
'name': "{/literal}{$product->name|escape:'htmlall':'UTF-8'}{literal}",
|
||||
'category': "{/literal}{$sale->title[$cookie->id_lang]}{literal}"
|
||||
});
|
||||
{/literal}
|
||||
{else if isset($page_name) && $page_name == 'order'}
|
||||
{literal}
|
||||
ga('require', 'ec');
|
||||
|
||||
ga('ec:setAction', 'detail');
|
||||
{/literal}
|
||||
{if $step == 0 || $step == 1}
|
||||
{if $cart}
|
||||
{assign var='cartProducts' value=$cart->getProducts()}
|
||||
{foreach from=$cartProducts item=cartProduct}
|
||||
{literal}
|
||||
ga('ec:addProduct', {
|
||||
'id': {/literal}{$cartProduct['id_product']}{literal},
|
||||
'name': "{/literal}{$cartProduct['name']}{literal}",
|
||||
'category': "{/literal}{$cartProduct['category']}{literal}",
|
||||
'price': {/literal}{Tools::ps_round(Product::getPriceStatic((int)$cartProduct['id_product'], true, ((isset($cartProduct['id_product_attribute']) AND !empty($cartProduct['id_product_attribute'])) ? (int)($cartProduct['id_product_attribute']) : NULL), 2), 2)}{literal},
|
||||
'quantity': {/literal}{$cartProduct['cart_quantity']}{literal}
|
||||
});
|
||||
{/literal}
|
||||
{/foreach}
|
||||
{/if}
|
||||
{/if}
|
||||
{literal}
|
||||
|
||||
{/literal}{else if isset($page_name) && $page_name == 'order'}{literal}
|
||||
ga('require', 'ec');
|
||||
{/literal}
|
||||
{if $step == 0}{literal}
|
||||
//cart
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 1,
|
||||
});
|
||||
{/literal}
|
||||
{else if $step == 1}{literal}
|
||||
// address
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 2,
|
||||
});
|
||||
{/literal}
|
||||
{else if $step == 2}{literal}
|
||||
// carrier
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 3,
|
||||
});
|
||||
{/literal}
|
||||
{else if $step == 3}{literal}
|
||||
// payment
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 4,
|
||||
});
|
||||
{/literal}
|
||||
{/if}
|
||||
{/if}
|
||||
{literal}
|
||||
|
||||
{/literal}
|
||||
{if $step == 0 || $step == 1}
|
||||
{if $cart}
|
||||
{assign var='cartProducts' value=$cart->getProducts()}
|
||||
{foreach from=$cartProducts item=cartProduct}
|
||||
{literal}
|
||||
ga('ec:addProduct', {
|
||||
'id': {/literal}{$cartProduct['id_product']}{literal},
|
||||
'name': "{/literal}{$cartProduct['name']}{literal}",
|
||||
'category': "{/literal}{$cartProduct['category']}{literal}",
|
||||
'price': {/literal}{Tools::ps_round(Product::getPriceStatic((int)$cartProduct['id_product'], true, ((isset($cartProduct['id_product_attribute']) AND !empty($cartProduct['id_product_attribute'])) ? (int)($cartProduct['id_product_attribute']) : NULL), 2), 2)}{literal},
|
||||
'quantity': {/literal}{$cartProduct['cart_quantity']}{literal}
|
||||
});
|
||||
{/literal}
|
||||
{/foreach}
|
||||
{/if}
|
||||
{/if}
|
||||
{literal}
|
||||
{/literal}
|
||||
{if isset($page_name) && (($page_name == 'order-confirmation' && $isEC==0) || $page_name != 'order-confirmation')}
|
||||
{literal}
|
||||
// send pageview via header.tpl du module GA si isEC=1 and $page_name == 'order-confirmation'
|
||||
var re = new RegExp("([?&])(email=)[^&#]*", "g");
|
||||
var re2 = new RegExp("([?&])(customer_lastname=)[^&#]*", "g");
|
||||
var re3 = new RegExp("([?&])(customer_firstname=)[^&#]*", "g");
|
||||
if (document.location.href.match(re) || document.location.href.match(re2) || document.location.href.match(re3)) {
|
||||
// remove personal data from url before sending to GA
|
||||
url = window.location.search.replace(re, '$1$2');
|
||||
url = url.replace(re2, '$1$2');
|
||||
url = url.replace(re3, '$1$2');
|
||||
var page = window.location.pathname+url;
|
||||
ga('send', 'pageview', page);
|
||||
} else {
|
||||
ga('send', 'pageview');
|
||||
}
|
||||
{/literal}
|
||||
{/if}
|
||||
{literal}
|
||||
|
||||
{/literal}{if $step == 0}{literal}
|
||||
//cart
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 1,
|
||||
});
|
||||
{/literal}{else if $step == 1}{literal}
|
||||
// address
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 2,
|
||||
});
|
||||
{/literal}{else if $step == 2}{literal}
|
||||
// carrier
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 3,
|
||||
});
|
||||
{/literal}{else if $step == 3}{literal}
|
||||
// payment
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 4,
|
||||
});
|
||||
{/literal}{/if}
|
||||
{/if}{literal}
|
||||
function onStepComplete(stepNumber, option, redirect, form) {
|
||||
ga('ec:setAction', 'checkout_option', {
|
||||
'step': stepNumber,
|
||||
'option': option
|
||||
});
|
||||
if (redirect != null) {
|
||||
ga('send', 'event', 'Checkout', 'Option', {
|
||||
hitCallback: function() {
|
||||
document.location = redirect;
|
||||
}
|
||||
});
|
||||
} else if (form != null) {
|
||||
ga('send', 'event', 'Checkout', 'Option', {
|
||||
hitCallback: function() {
|
||||
form.submit();
|
||||
}
|
||||
});
|
||||
} else {
|
||||
ga('send', 'event', 'Checkout', 'Option', {});
|
||||
}
|
||||
}
|
||||
function addToCartToGA(product) {
|
||||
ga('ec:addProduct', {
|
||||
'id': product.id,
|
||||
'name': product.name,
|
||||
'brand': product.category,
|
||||
'category': product.category,
|
||||
'variant' : product.variant,
|
||||
'price': product.price,
|
||||
'quantity': product.qty
|
||||
});
|
||||
ga('ec:setAction', 'add');
|
||||
ga('send', 'event', 'UX', 'click', 'add to cart');
|
||||
}
|
||||
function removeFromCartToGA(product) {
|
||||
ga('ec:addProduct', {
|
||||
'id': product.id,
|
||||
'name': product.name,
|
||||
'brand': product.category,
|
||||
'category': product.category,
|
||||
'variant' : product.variant,
|
||||
'price': product.price,
|
||||
'quantity': product.qty
|
||||
});
|
||||
ga('ec:setAction', 'remove');
|
||||
ga('send', 'event', 'UX', 'click', 'remove to cart');
|
||||
}
|
||||
</script>
|
||||
{/literal}
|
||||
{elseif $cookie->id_lang == 3}
|
||||
{literal}
|
||||
<script>
|
||||
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
|
||||
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
|
||||
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
|
||||
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
|
||||
|
||||
{/literal}{if isset($page_name) && (($page_name == 'order-confirmation' && $isEC==0) || $page_name != 'order-confirmation')}{literal}
|
||||
// send pageview via header.tpl du module GA si isEC=1 and $page_name == 'order-confirmation'
|
||||
ga('create', 'UA-68580471-1', 'auto');
|
||||
{/literal}
|
||||
{if isset($page_name) && $page_name == 'category'}
|
||||
{literal}
|
||||
ga('require', 'ec');
|
||||
|
||||
var re = new RegExp("([?&])(email=)[^&#]*", "g");
|
||||
var re2 = new RegExp("([?&])(customer_lastname=)[^&#]*", "g");
|
||||
var re3 = new RegExp("([?&])(customer_firstname=)[^&#]*", "g");
|
||||
if (document.location.href.match(re) || document.location.href.match(re2) || document.location.href.match(re3)) {
|
||||
// remove personal data from url before sending to GA
|
||||
url = window.location.search.replace(re, '$1$2');
|
||||
url = url.replace(re2, '$1$2');
|
||||
url = url.replace(re3, '$1$2');
|
||||
var page = window.location.pathname+url;
|
||||
ga('send', 'pageview', page);
|
||||
} else {
|
||||
ga('send', 'pageview');
|
||||
}
|
||||
{/literal}
|
||||
{else if isset($page_name) && $page_name == 'product'}
|
||||
{literal}
|
||||
ga('require', 'ec');
|
||||
ga('ec:addProduct', {
|
||||
'id': {/literal}{$product->id}{literal},
|
||||
'name': "{/literal}{$product->name|escape:'htmlall':'UTF-8'}{literal}",
|
||||
'category': "{/literal}{$sale->title[$cookie->id_lang]}{literal}"
|
||||
});
|
||||
|
||||
ga('ec:setAction', 'detail');
|
||||
|
||||
{/literal}{/if}{literal}
|
||||
{/literal}
|
||||
{else if isset($page_name) && $page_name == 'order'}
|
||||
{literal}
|
||||
ga('require', 'ec');
|
||||
|
||||
function onStepComplete(stepNumber, option, redirect, form) {
|
||||
ga('ec:setAction', 'checkout_option', {
|
||||
'step': stepNumber,
|
||||
'option': option
|
||||
});
|
||||
if (redirect != null) {
|
||||
ga('send', 'event', 'Checkout', 'Option', {
|
||||
hitCallback: function() {
|
||||
document.location = redirect;
|
||||
}
|
||||
});
|
||||
} else if (form != null) {
|
||||
ga('send', 'event', 'Checkout', 'Option', {
|
||||
hitCallback: function() {
|
||||
form.submit();
|
||||
}
|
||||
});
|
||||
} else {
|
||||
ga('send', 'event', 'Checkout', 'Option', {});
|
||||
}
|
||||
}
|
||||
function addToCartToGA(product) {
|
||||
ga('ec:addProduct', {
|
||||
'id': product.id,
|
||||
'name': product.name,
|
||||
'brand': product.category,
|
||||
'category': product.category,
|
||||
'variant' : product.variant,
|
||||
'price': product.price,
|
||||
'quantity': product.qty
|
||||
});
|
||||
ga('ec:setAction', 'add');
|
||||
ga('send', 'event', 'UX', 'click', 'add to cart');
|
||||
}
|
||||
function removeFromCartToGA(product) {
|
||||
ga('ec:addProduct', {
|
||||
'id': product.id,
|
||||
'name': product.name,
|
||||
'brand': product.category,
|
||||
'category': product.category,
|
||||
'variant' : product.variant,
|
||||
'price': product.price,
|
||||
'quantity': product.qty
|
||||
});
|
||||
ga('ec:setAction', 'remove');
|
||||
ga('send', 'event', 'UX', 'click', 'remove to cart');
|
||||
}
|
||||
</script>
|
||||
{/literal}
|
||||
{elseif $cookie->id_lang == 3}
|
||||
{literal}
|
||||
<script>
|
||||
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
|
||||
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
|
||||
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
|
||||
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
|
||||
{/literal}
|
||||
{if $step == 0 || $step == 1}
|
||||
{if $cart}
|
||||
{assign var='cartProducts' value=$cart->getProducts()}
|
||||
{foreach from=$cartProducts item=cartProduct}
|
||||
{literal}
|
||||
ga('ec:addProduct', {
|
||||
'id': {/literal}{$cartProduct['id_product']}{literal},
|
||||
'name': "{/literal}{$cartProduct['name']}{literal}",
|
||||
'category': "{/literal}{$cartProduct['category']}{literal}",
|
||||
'price': {/literal}{Tools::ps_round(Product::getPriceStatic((int)$cartProduct['id_product'], true, ((isset($cartProduct['id_product_attribute']) AND !empty($cartProduct['id_product_attribute'])) ? (int)($cartProduct['id_product_attribute']) : NULL), 2), 2)}{literal},
|
||||
'quantity': {/literal}{$cartProduct['cart_quantity']}{literal}
|
||||
});
|
||||
{/literal}
|
||||
{/foreach}
|
||||
{/if}
|
||||
{/if}
|
||||
{literal}
|
||||
|
||||
{/literal}
|
||||
{if $step == 0}
|
||||
{literal}
|
||||
//cart
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 1,
|
||||
});
|
||||
{/literal}
|
||||
{else if $step == 1}
|
||||
{literal}
|
||||
// address
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 2,
|
||||
});
|
||||
{/literal}
|
||||
{else if $step == 2}
|
||||
{literal}
|
||||
// carrier
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 3,
|
||||
});
|
||||
{/literal}
|
||||
else if $step == 3}
|
||||
{literal}
|
||||
// payment
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 4,
|
||||
});
|
||||
{/literal}
|
||||
{/if}
|
||||
{/if}
|
||||
{literal}
|
||||
|
||||
ga('create', 'UA-68580471-1', 'auto');
|
||||
{/literal}
|
||||
{if isset($page_name) && (($page_name == 'order-confirmation' && $isEC==0) || $page_name != 'order-confirmation')}
|
||||
{literal}
|
||||
// send pageview via header.tpl du module GA si isEC=1 and $page_name == 'order-confirmation'
|
||||
var re = new RegExp("([?&])(email=)[^&#]*", "g");
|
||||
var re2 = new RegExp("([?&])(customer_lastname=)[^&#]*", "g");
|
||||
var re3 = new RegExp("([?&])(customer_firstname=)[^&#]*", "g");
|
||||
if (document.location.href.match(re) || document.location.href.match(re2) || document.location.href.match(re3)) {
|
||||
// remove personal data from url before sending to GA
|
||||
url = window.location.search.replace(re, '$1$2');
|
||||
url = url.replace(re2, '$1$2');
|
||||
url = url.replace(re3, '$1$2');
|
||||
var page = window.location.pathname+url;
|
||||
ga('send', 'pageview', page);
|
||||
} else {
|
||||
ga('send', 'pageview');
|
||||
}
|
||||
{/literal}
|
||||
{/if}
|
||||
{literal}
|
||||
|
||||
{/literal}{if isset($page_name) && $page_name == 'category'}{literal}
|
||||
ga('require', 'ec');
|
||||
function onStepComplete(stepNumber, option, redirect, form) {
|
||||
ga('ec:setAction', 'checkout_option', {
|
||||
'step': stepNumber,
|
||||
'option': option
|
||||
});
|
||||
if (redirect != null) {
|
||||
ga('send', 'event', 'Checkout', 'Option', {
|
||||
hitCallback: function() {
|
||||
document.location = redirect;
|
||||
}
|
||||
});
|
||||
} else if (form != null) {
|
||||
ga('send', 'event', 'Checkout', 'Option', {
|
||||
hitCallback: function() {
|
||||
form.submit();
|
||||
}
|
||||
});
|
||||
} else {
|
||||
ga('send', 'event', 'Checkout', 'Option', {});
|
||||
}
|
||||
}
|
||||
function addToCartToGA(product) {
|
||||
ga('ec:addProduct', {
|
||||
'id': product.id,
|
||||
'name': product.name,
|
||||
'brand': product.category,
|
||||
'category': product.category,
|
||||
'variant' : product.variant,
|
||||
'price': product.price,
|
||||
'quantity': product.qty
|
||||
});
|
||||
ga('ec:setAction', 'add');
|
||||
ga('send', 'event', 'UX', 'click', 'add to cart');
|
||||
}
|
||||
function removeFromCartToGA(product) {
|
||||
ga('ec:addProduct', {
|
||||
'id': product.id,
|
||||
'name': product.name,
|
||||
'brand': product.category,
|
||||
'category': product.category,
|
||||
'variant' : product.variant,
|
||||
'price': product.price,
|
||||
'quantity': product.qty
|
||||
});
|
||||
ga('ec:setAction', 'remove');
|
||||
ga('send', 'event', 'UX', 'click', 'remove to cart');
|
||||
}
|
||||
</script>
|
||||
{/literal}
|
||||
{/if}
|
||||
|
||||
{/literal}{else if isset($page_name) && $page_name == 'product'}{literal}
|
||||
ga('require', 'ec');
|
||||
ga('ec:addProduct', {
|
||||
'id': {/literal}{$product->id}{literal},
|
||||
'name': "{/literal}{$product->name|escape:'htmlall':'UTF-8'}{literal}",
|
||||
'category': "{/literal}{$sale->title[$cookie->id_lang]}{literal}"
|
||||
});
|
||||
<!-- Facebook Pixel Code -->
|
||||
{if $cookie->id_lang == 2}
|
||||
{literal}
|
||||
<script>
|
||||
!function(f,b,e,v,n,t,s){if(f.fbq)return;n=f.fbq=function(){n.callMethod?
|
||||
n.callMethod.apply(n,arguments):n.queue.push(arguments)};if(!f._fbq)f._fbq=n;
|
||||
n.push=n;n.loaded=!0;n.version='2.0';n.queue=[];t=b.createElement(e);t.async=!0;
|
||||
t.src=v;s=b.getElementsByTagName(e)[0];s.parentNode.insertBefore(t,s)}(window,
|
||||
document,'script','//connect.facebook.net/en_US/fbevents.js');
|
||||
|
||||
ga('ec:setAction', 'detail');
|
||||
fbq('init', '585280634957856');
|
||||
fbq('track', "PageView");
|
||||
</script>
|
||||
{/literal}
|
||||
<noscript><img height="1" width="1" style="display:none" src="https://www.facebook.com/tr?id=585280634957856&ev=PageView&noscript=1"/></noscript>
|
||||
{elseif $cookie->id_lang == 3}
|
||||
{literal}
|
||||
<script>
|
||||
!function(f,b,e,v,n,t,s){if(f.fbq)return;n=f.fbq=function(){n.callMethod?
|
||||
n.callMethod.apply(n,arguments):n.queue.push(arguments)};if(!f._fbq)f._fbq=n;
|
||||
n.push=n;n.loaded=!0;n.version='2.0';n.queue=[];t=b.createElement(e);t.async=!0;
|
||||
t.src=v;s=b.getElementsByTagName(e)[0];s.parentNode.insertBefore(t,s)}(window,
|
||||
document,'script','//connect.facebook.net/en_US/fbevents.js');
|
||||
|
||||
{/literal}{else if isset($page_name) && $page_name == 'order'}{literal}
|
||||
ga('require', 'ec');
|
||||
|
||||
{/literal}
|
||||
{if $step == 0 || $step == 1}
|
||||
{if $cart}
|
||||
{assign var='cartProducts' value=$cart->getProducts()}
|
||||
{foreach from=$cartProducts item=cartProduct}
|
||||
{literal}
|
||||
ga('ec:addProduct', {
|
||||
'id': {/literal}{$cartProduct['id_product']}{literal},
|
||||
'name': "{/literal}{$cartProduct['name']}{literal}",
|
||||
'category': "{/literal}{$cartProduct['category']}{literal}",
|
||||
'price': {/literal}{Tools::ps_round(Product::getPriceStatic((int)$cartProduct['id_product'], true, ((isset($cartProduct['id_product_attribute']) AND !empty($cartProduct['id_product_attribute'])) ? (int)($cartProduct['id_product_attribute']) : NULL), 2), 2)}{literal},
|
||||
'quantity': {/literal}{$cartProduct['cart_quantity']}{literal}
|
||||
});
|
||||
{/literal}
|
||||
{/foreach}
|
||||
{/if}
|
||||
{/if}
|
||||
{literal}
|
||||
|
||||
{/literal}{if $step == 0}{literal}
|
||||
//cart
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 1,
|
||||
});
|
||||
{/literal}{else if $step == 1}{literal}
|
||||
// address
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 2,
|
||||
});
|
||||
{/literal}{else if $step == 2}{literal}
|
||||
// carrier
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 3,
|
||||
});
|
||||
{/literal}{else if $step == 3}{literal}
|
||||
// payment
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 4,
|
||||
});
|
||||
{/literal}{/if}
|
||||
{/if}{literal}
|
||||
|
||||
{/literal}{if isset($page_name) && (($page_name == 'order-confirmation' && $isEC==0) || $page_name != 'order-confirmation')}{literal}
|
||||
// send pageview via header.tpl du module GA si isEC=1 and $page_name == 'order-confirmation'
|
||||
|
||||
var re = new RegExp("([?&])(email=)[^&#]*", "g");
|
||||
var re2 = new RegExp("([?&])(customer_lastname=)[^&#]*", "g");
|
||||
var re3 = new RegExp("([?&])(customer_firstname=)[^&#]*", "g");
|
||||
if (document.location.href.match(re) || document.location.href.match(re2) || document.location.href.match(re3)) {
|
||||
// remove personal data from url before sending to GA
|
||||
url = window.location.search.replace(re, '$1$2');
|
||||
url = url.replace(re2, '$1$2');
|
||||
url = url.replace(re3, '$1$2');
|
||||
var page = window.location.pathname+url;
|
||||
ga('send', 'pageview', page);
|
||||
} else {
|
||||
ga('send', 'pageview');
|
||||
}
|
||||
{/literal}{/if}{literal}
|
||||
|
||||
function onStepComplete(stepNumber, option, redirect, form) {
|
||||
ga('ec:setAction', 'checkout_option', {
|
||||
'step': stepNumber,
|
||||
'option': option
|
||||
});
|
||||
if (redirect != null) {
|
||||
ga('send', 'event', 'Checkout', 'Option', {
|
||||
hitCallback: function() {
|
||||
document.location = redirect;
|
||||
}
|
||||
});
|
||||
} else if (form != null) {
|
||||
ga('send', 'event', 'Checkout', 'Option', {
|
||||
hitCallback: function() {
|
||||
form.submit();
|
||||
}
|
||||
});
|
||||
} else {
|
||||
ga('send', 'event', 'Checkout', 'Option', {});
|
||||
}
|
||||
}
|
||||
function addToCartToGA(product) {
|
||||
ga('ec:addProduct', {
|
||||
'id': product.id,
|
||||
'name': product.name,
|
||||
'brand': product.category,
|
||||
'category': product.category,
|
||||
'variant' : product.variant,
|
||||
'price': product.price,
|
||||
'quantity': product.qty
|
||||
});
|
||||
ga('ec:setAction', 'add');
|
||||
ga('send', 'event', 'UX', 'click', 'add to cart');
|
||||
}
|
||||
function removeFromCartToGA(product) {
|
||||
ga('ec:addProduct', {
|
||||
'id': product.id,
|
||||
'name': product.name,
|
||||
'brand': product.category,
|
||||
'category': product.category,
|
||||
'variant' : product.variant,
|
||||
'price': product.price,
|
||||
'quantity': product.qty
|
||||
});
|
||||
ga('ec:setAction', 'remove');
|
||||
ga('send', 'event', 'UX', 'click', 'remove to cart');
|
||||
}
|
||||
</script>
|
||||
{/literal}
|
||||
{/if}
|
||||
|
||||
<!-- Facebook Pixel Code -->
|
||||
{if $cookie->id_lang == 2}
|
||||
{literal}
|
||||
<script>
|
||||
!function(f,b,e,v,n,t,s){if(f.fbq)return;n=f.fbq=function(){n.callMethod?
|
||||
n.callMethod.apply(n,arguments):n.queue.push(arguments)};if(!f._fbq)f._fbq=n;
|
||||
n.push=n;n.loaded=!0;n.version='2.0';n.queue=[];t=b.createElement(e);t.async=!0;
|
||||
t.src=v;s=b.getElementsByTagName(e)[0];s.parentNode.insertBefore(t,s)}(window,
|
||||
document,'script','//connect.facebook.net/en_US/fbevents.js');
|
||||
|
||||
fbq('init', '585280634957856');
|
||||
fbq('track', "PageView");
|
||||
</script>
|
||||
{/literal}
|
||||
<noscript><img height="1" width="1" style="display:none" src="https://www.facebook.com/tr?id=585280634957856&ev=PageView&noscript=1"/></noscript>
|
||||
{elseif $cookie->id_lang == 3}
|
||||
{literal}
|
||||
<script>
|
||||
!function(f,b,e,v,n,t,s){if(f.fbq)return;n=f.fbq=function(){n.callMethod?
|
||||
n.callMethod.apply(n,arguments):n.queue.push(arguments)};if(!f._fbq)f._fbq=n;
|
||||
n.push=n;n.loaded=!0;n.version='2.0';n.queue=[];t=b.createElement(e);t.async=!0;
|
||||
t.src=v;s=b.getElementsByTagName(e)[0];s.parentNode.insertBefore(t,s)}(window,
|
||||
document,'script','//connect.facebook.net/en_US/fbevents.js');
|
||||
|
||||
fbq('init', '778018572325168');
|
||||
fbq('track', "PageView");
|
||||
</script>
|
||||
{/literal}
|
||||
<noscript><img height="1" width="1" style="display:none" src="https://www.facebook.com/tr?id=778018572325168&ev=PageView&noscript=1"/></noscript>
|
||||
{/if}
|
||||
|
||||
{literal}
|
||||
<script>
|
||||
fbq('track', 'ViewContent', {
|
||||
content_name:'{/literal}{$page_name|escape:'html':'UTF-8'}{literal}'
|
||||
fbq('init', '778018572325168');
|
||||
fbq('track', "PageView");
|
||||
</script>
|
||||
{/literal}
|
||||
<noscript><img height="1" width="1" style="display:none" src="https://www.facebook.com/tr?id=778018572325168&ev=PageView&noscript=1"/></noscript>
|
||||
{/if}
|
||||
|
||||
{literal}
|
||||
<script>
|
||||
fbq('track', 'ViewContent', {
|
||||
content_name:'{/literal}{$page_name|escape:'html':'UTF-8'}{literal}'
|
||||
});
|
||||
</script>
|
||||
{/literal}
|
||||
{if isset($facebook_validation) && $facebook_validation}
|
||||
{literal}
|
||||
<script>
|
||||
fbq('track', 'CompleteRegistration');
|
||||
</script>
|
||||
{/literal}
|
||||
{/if}
|
||||
|
||||
{$currency|@print_r}
|
||||
|
||||
{if isset($page_name)}
|
||||
{if $page_name == 'order-confirmation' && isset($order)}
|
||||
{literal}
|
||||
<script>
|
||||
fbq('track', 'Purchase', {
|
||||
value: '{/literal}{$order->total_paid}{literal}',
|
||||
currency: "{/literal}{$currency['iso_code']}{literal}"
|
||||
});
|
||||
</script>
|
||||
{/literal}
|
||||
{if isset($facebook_validation) && $facebook_validation}
|
||||
{literal}
|
||||
<script>
|
||||
fbq('track', 'CompleteRegistration');
|
||||
</script>
|
||||
{/literal}
|
||||
{/if}
|
||||
|
||||
{if isset($page_name)}
|
||||
{if $page_name == 'order-confirmation' && isset($order)}
|
||||
{literal}
|
||||
<script>
|
||||
fbq('track', 'Purchase', {
|
||||
value: '{/literal}{$order->total_paid}{literal}',
|
||||
currency: "{/literal}{$currencyIsoCode}{literal}"
|
||||
});
|
||||
</script>
|
||||
{/literal}
|
||||
{/if}
|
||||
{/if}
|
||||
<!-- End Facebook Pixel Code -->
|
||||
|
||||
<!-- crazyegg -->
|
||||
{literal}
|
||||
<script type="text/javascript">
|
||||
setTimeout(function(){var a=document.createElement("script");
|
||||
var b=document.getElementsByTagName("script")[0];
|
||||
a.src=document.location.protocol+"//script.crazyegg.com/pages/scripts/0047/9841.js?"+Math.floor(new Date().getTime()/3600000);
|
||||
a.async=true;a.type="text/javascript";b.parentNode.insertBefore(a,b)}, 1);
|
||||
</script>
|
||||
{/literal}
|
||||
</script>
|
||||
{/literal}
|
||||
{/if}
|
||||
{/if}
|
||||
<!-- End Facebook Pixel Code -->
|
||||
|
||||
<!-- crazyegg -->
|
||||
{literal}
|
||||
<script type="text/javascript">
|
||||
setTimeout(function(){var a=document.createElement("script");
|
||||
var b=document.getElementsByTagName("script")[0];
|
||||
a.src=document.location.protocol+"//script.crazyegg.com/pages/scripts/0047/9841.js?"+Math.floor(new Date().getTime()/3600000);
|
||||
a.async=true;a.type="text/javascript";b.parentNode.insertBefore(a,b)}, 1);
|
||||
</script>
|
||||
{/literal}
|
||||
|
||||
</head>
|
||||
|
||||
<body {if $page_name}id="{$page_name|escape:'htmlall':'UTF-8'}"{/if} class="{$bodyClass}{if $cookie->isLogged()} logged{/if}{if isset($smarty.get.content_only)} content_only{/if}{if isset($smarty.post.email_create) || isset($smarty.get.create_account)} create{/if} lang{$cookie->id_lang}">
|
||||
|
||||
<!-- Google Tag Manager (noscript) -->
|
||||
<noscript><iframe src="https://www.googletagmanager.com/ns.html?id=GTM-PT7ZGQF" height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
|
||||
<noscript><iframe src="https://www.googletagmanager.com/ns.html?id=GTM-PT7ZGQF"
|
||||
height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
|
||||
<!-- End Google Tag Manager (noscript) -->
|
||||
|
||||
{if !$content_only}
|
||||
|
@ -79,372 +79,398 @@
|
||||
<!-- Google Tag Manager -->
|
||||
{literal}
|
||||
<script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':
|
||||
new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],
|
||||
j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=
|
||||
'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);
|
||||
})(window,document,'script','dataLayer','GTM-PT7ZGQF');</script>
|
||||
new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],
|
||||
j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=
|
||||
'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);
|
||||
})(window,document,'script','dataLayer','GTM-PT7ZGQF');</script>
|
||||
{/literal}
|
||||
<!-- End Google Tag Manager -->
|
||||
|
||||
{assign var='isEC' value=Configuration::get('GANALYTICS_EC')}
|
||||
{if $cookie->id_lang == 2}
|
||||
{literal}
|
||||
<script>
|
||||
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
|
||||
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
|
||||
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
|
||||
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
|
||||
|
||||
ga('create', 'UA-30665119-1', 'auto');
|
||||
{/literal}{if isset($page_name) && $page_name == 'category'}{literal}
|
||||
ga('require', 'ec');
|
||||
|
||||
{/literal}{else if isset($page_name) && $page_name == 'product'}{literal}
|
||||
ga('require', 'ec');
|
||||
ga('ec:addProduct', {
|
||||
'id': {/literal}{$product->id}{literal},
|
||||
'name': "{/literal}{$product->name|escape:'htmlall':'UTF-8'}{literal}",
|
||||
'category': "{/literal}{$sale->title[$cookie->id_lang]}{literal}"
|
||||
});
|
||||
|
||||
ga('ec:setAction', 'detail');
|
||||
|
||||
{/literal}{else if isset($page_name) && $page_name == 'order'}{literal}
|
||||
ga('require', 'ec');
|
||||
|
||||
{/literal}
|
||||
{if $step == 0 || $step == 1}
|
||||
{if $cart}
|
||||
{assign var='cartProducts' value=$cart->getProducts()}
|
||||
{foreach from=$cartProducts item=cartProduct}
|
||||
{literal}
|
||||
ga('ec:addProduct', {
|
||||
'id': {/literal}{$cartProduct['id_product']}{literal},
|
||||
'name': "{/literal}{$cartProduct['name']}{literal}",
|
||||
'category': "{/literal}{$cartProduct['category']}{literal}",
|
||||
'price': {/literal}{Tools::ps_round(Product::getPriceStatic((int)$cartProduct['id_product'], true, ((isset($cartProduct['id_product_attribute']) AND !empty($cartProduct['id_product_attribute'])) ? (int)($cartProduct['id_product_attribute']) : NULL), 2), 2)}{literal},
|
||||
'quantity': {/literal}{$cartProduct['cart_quantity']}{literal}
|
||||
});
|
||||
{/literal}
|
||||
{/foreach}
|
||||
{/if}
|
||||
{/if}
|
||||
{literal}
|
||||
|
||||
{/literal}{if $step == 0}{literal}
|
||||
//cart
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 1,
|
||||
});
|
||||
{/literal}{else if $step == 1}{literal}
|
||||
// address
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 2,
|
||||
});
|
||||
{/literal}{else if $step == 2}{literal}
|
||||
// carrier
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 3,
|
||||
});
|
||||
{/literal}{else if $step == 3}{literal}
|
||||
// payment
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 4,
|
||||
});
|
||||
{/literal}{/if}
|
||||
{/if}{literal}
|
||||
|
||||
{/literal}{if isset($page_name) && (($page_name == 'order-confirmation' && $isEC==0) || $page_name != 'order-confirmation')}{literal}
|
||||
// send pageview via header.tpl du module GA si isEC=1 and $page_name == 'order-confirmation'
|
||||
|
||||
var re = new RegExp("([?&])(email=)[^&#]*", "g");
|
||||
var re2 = new RegExp("([?&])(customer_lastname=)[^&#]*", "g");
|
||||
var re3 = new RegExp("([?&])(customer_firstname=)[^&#]*", "g");
|
||||
if (document.location.href.match(re) || document.location.href.match(re2) || document.location.href.match(re3)) {
|
||||
// remove personal data from url before sending to GA
|
||||
url = window.location.search.replace(re, '$1$2');
|
||||
url = url.replace(re2, '$1$2');
|
||||
url = url.replace(re3, '$1$2');
|
||||
var page = window.location.pathname+url;
|
||||
ga('send', 'pageview', page);
|
||||
} else {
|
||||
ga('send', 'pageview');
|
||||
}
|
||||
{/literal}{/if}{literal}
|
||||
|
||||
function onStepComplete(stepNumber, option, redirect, form) {
|
||||
ga('ec:setAction', 'checkout_option', {
|
||||
'step': stepNumber,
|
||||
'option': option
|
||||
});
|
||||
if (redirect != null) {
|
||||
ga('send', 'event', 'Checkout', 'Option', {
|
||||
hitCallback: function() {
|
||||
document.location = redirect;
|
||||
}
|
||||
});
|
||||
} else if (form != null) {
|
||||
ga('send', 'event', 'Checkout', 'Option', {
|
||||
hitCallback: function() {
|
||||
form.submit();
|
||||
}
|
||||
});
|
||||
} else {
|
||||
ga('send', 'event', 'Checkout', 'Option', {});
|
||||
}
|
||||
}
|
||||
function addToCartToGA(product) {
|
||||
ga('ec:addProduct', {
|
||||
'id': product.id,
|
||||
'name': product.name,
|
||||
'brand': product.category,
|
||||
'category': product.category,
|
||||
'variant' : product.variant,
|
||||
'price': product.price,
|
||||
'quantity': product.qty
|
||||
});
|
||||
ga('ec:setAction', 'add');
|
||||
ga('send', 'event', 'UX', 'click', 'add to cart');
|
||||
}
|
||||
function removeFromCartToGA(product) {
|
||||
ga('ec:addProduct', {
|
||||
'id': product.id,
|
||||
'name': product.name,
|
||||
'brand': product.category,
|
||||
'category': product.category,
|
||||
'variant' : product.variant,
|
||||
'price': product.price,
|
||||
'quantity': product.qty
|
||||
});
|
||||
ga('ec:setAction', 'remove');
|
||||
ga('send', 'event', 'UX', 'click', 'remove to cart');
|
||||
}
|
||||
</script>
|
||||
{/literal}
|
||||
{elseif $cookie->id_lang == 3}
|
||||
{literal}
|
||||
<script>
|
||||
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
|
||||
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
|
||||
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
|
||||
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
|
||||
|
||||
ga('create', 'UA-68580471-1', 'auto');
|
||||
{/literal}{if isset($page_name) && $page_name == 'category'}{literal}
|
||||
ga('require', 'ec');
|
||||
|
||||
{/literal}{else if isset($page_name) && $page_name == 'product'}{literal}
|
||||
ga('require', 'ec');
|
||||
ga('ec:addProduct', {
|
||||
'id': {/literal}{$product->id}{literal},
|
||||
'name': "{/literal}{$product->name|escape:'htmlall':'UTF-8'}{literal}",
|
||||
'category': "{/literal}{$sale->title[$cookie->id_lang]}{literal}"
|
||||
});
|
||||
|
||||
ga('ec:setAction', 'detail');
|
||||
|
||||
{/literal}{else if isset($page_name) && $page_name == 'order'}{literal}
|
||||
ga('require', 'ec');
|
||||
|
||||
{/literal}
|
||||
{if $step == 0 || $step == 1}
|
||||
{if $cart}
|
||||
{assign var='cartProducts' value=$cart->getProducts()}
|
||||
{foreach from=$cartProducts item=cartProduct}
|
||||
{literal}
|
||||
ga('ec:addProduct', {
|
||||
'id': {/literal}{$cartProduct['id_product']}{literal},
|
||||
'name': "{/literal}{$cartProduct['name']}{literal}",
|
||||
'category': "{/literal}{$cartProduct['category']}{literal}",
|
||||
'price': {/literal}{Tools::ps_round(Product::getPriceStatic((int)$cartProduct['id_product'], true, ((isset($cartProduct['id_product_attribute']) AND !empty($cartProduct['id_product_attribute'])) ? (int)($cartProduct['id_product_attribute']) : NULL), 2), 2)}{literal},
|
||||
'quantity': {/literal}{$cartProduct['cart_quantity']}{literal}
|
||||
});
|
||||
{/literal}
|
||||
{/foreach}
|
||||
{/if}
|
||||
{/if}
|
||||
{literal}
|
||||
|
||||
{/literal}{if $step == 0}{literal}
|
||||
//cart
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 1,
|
||||
});
|
||||
{/literal}{else if $step == 1}{literal}
|
||||
// address
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 2,
|
||||
});
|
||||
{/literal}{else if $step == 2}{literal}
|
||||
// carrier
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 3,
|
||||
});
|
||||
{/literal}{else if $step == 3}{literal}
|
||||
// payment
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 4,
|
||||
});
|
||||
{/literal}{/if}
|
||||
{/if}{literal}
|
||||
|
||||
{/literal}{if isset($page_name) && (($page_name == 'order-confirmation' && $isEC==0) || $page_name != 'order-confirmation')}{literal}
|
||||
// send pageview via header.tpl du module GA si isEC=1 and $page_name == 'order-confirmation'
|
||||
|
||||
var re = new RegExp("([?&])(email=)[^&#]*", "g");
|
||||
var re2 = new RegExp("([?&])(customer_lastname=)[^&#]*", "g");
|
||||
var re3 = new RegExp("([?&])(customer_firstname=)[^&#]*", "g");
|
||||
if (document.location.href.match(re) || document.location.href.match(re2) || document.location.href.match(re3)) {
|
||||
// remove personal data from url before sending to GA
|
||||
url = window.location.search.replace(re, '$1$2');
|
||||
url = url.replace(re2, '$1$2');
|
||||
url = url.replace(re3, '$1$2');
|
||||
var page = window.location.pathname+url;
|
||||
ga('send', 'pageview', page);
|
||||
} else {
|
||||
ga('send', 'pageview');
|
||||
}
|
||||
{/literal}{/if}{literal}
|
||||
|
||||
function onStepComplete(stepNumber, option, redirect, form) {
|
||||
ga('ec:setAction', 'checkout_option', {
|
||||
'step': stepNumber,
|
||||
'option': option
|
||||
});
|
||||
if (redirect != null) {
|
||||
ga('send', 'event', 'Checkout', 'Option', {
|
||||
hitCallback: function() {
|
||||
document.location = redirect;
|
||||
}
|
||||
});
|
||||
} else if (form != null) {
|
||||
ga('send', 'event', 'Checkout', 'Option', {
|
||||
hitCallback: function() {
|
||||
form.submit();
|
||||
}
|
||||
});
|
||||
} else {
|
||||
ga('send', 'event', 'Checkout', 'Option', {});
|
||||
}
|
||||
}
|
||||
function addToCartToGA(product) {
|
||||
ga('ec:addProduct', {
|
||||
'id': product.id,
|
||||
'name': product.name,
|
||||
'brand': product.category,
|
||||
'category': product.category,
|
||||
'variant' : product.variant,
|
||||
'price': product.price,
|
||||
'quantity': product.qty
|
||||
});
|
||||
ga('ec:setAction', 'add');
|
||||
ga('send', 'event', 'UX', 'click', 'add to cart');
|
||||
}
|
||||
function removeFromCartToGA(product) {
|
||||
ga('ec:addProduct', {
|
||||
'id': product.id,
|
||||
'name': product.name,
|
||||
'brand': product.category,
|
||||
'category': product.category,
|
||||
'variant' : product.variant,
|
||||
'price': product.price,
|
||||
'quantity': product.qty
|
||||
});
|
||||
ga('ec:setAction', 'remove');
|
||||
ga('send', 'event', 'UX', 'click', 'remove to cart');
|
||||
}
|
||||
</script>
|
||||
{/literal}
|
||||
{/if}
|
||||
|
||||
<!-- Facebook Pixel Code -->
|
||||
{if $cookie->id_lang == 2}
|
||||
{literal}
|
||||
<script>
|
||||
!function(f,b,e,v,n,t,s){if(f.fbq)return;n=f.fbq=function(){n.callMethod?
|
||||
n.callMethod.apply(n,arguments):n.queue.push(arguments)};if(!f._fbq)f._fbq=n;
|
||||
n.push=n;n.loaded=!0;n.version='2.0';n.queue=[];t=b.createElement(e);t.async=!0;
|
||||
t.src=v;s=b.getElementsByTagName(e)[0];s.parentNode.insertBefore(t,s)}(window,
|
||||
document,'script','//connect.facebook.net/en_US/fbevents.js');
|
||||
|
||||
fbq('init', '585280634957856');
|
||||
fbq('track', "PageView");
|
||||
</script>
|
||||
{/literal}
|
||||
<noscript><img height="1" width="1" style="display:none" src="https://www.facebook.com/tr?id=585280634957856&ev=PageView&noscript=1"/></noscript>
|
||||
{elseif $cookie->id_lang == 3}
|
||||
{literal}
|
||||
<script>
|
||||
!function(f,b,e,v,n,t,s){if(f.fbq)return;n=f.fbq=function(){n.callMethod?
|
||||
n.callMethod.apply(n,arguments):n.queue.push(arguments)};if(!f._fbq)f._fbq=n;
|
||||
n.push=n;n.loaded=!0;n.version='2.0';n.queue=[];t=b.createElement(e);t.async=!0;
|
||||
t.src=v;s=b.getElementsByTagName(e)[0];s.parentNode.insertBefore(t,s)}(window,
|
||||
document,'script','//connect.facebook.net/en_US/fbevents.js');
|
||||
|
||||
fbq('init', '778018572325168');
|
||||
fbq('track', "PageView");
|
||||
</script>
|
||||
{/literal}
|
||||
<noscript><img height="1" width="1" style="display:none" src="https://www.facebook.com/tr?id=778018572325168&ev=PageView&noscript=1"/></noscript>
|
||||
{/if}
|
||||
|
||||
{if $cookie->id_lang == 2}
|
||||
{literal}
|
||||
<script>
|
||||
fbq('track', 'ViewContent', {
|
||||
content_name:'{/literal}{$page_name|escape:'html':'UTF-8'}{literal}'
|
||||
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
|
||||
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
|
||||
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
|
||||
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
|
||||
|
||||
ga('create', 'UA-30665119-1', 'auto');
|
||||
{/literal}
|
||||
{if isset($page_name) && $page_name == 'category'}
|
||||
{literal}
|
||||
ga('require', 'ec');
|
||||
|
||||
{/literal}
|
||||
{else if isset($page_name) && $page_name == 'product'}
|
||||
{literal}
|
||||
ga('require', 'ec');
|
||||
ga('ec:addProduct', {
|
||||
'id': {/literal}{$product->id}{literal},
|
||||
'name': "{/literal}{$product->name|escape:'htmlall':'UTF-8'}{literal}",
|
||||
'category': "{/literal}{$sale->title[$cookie->id_lang]}{literal}"
|
||||
});
|
||||
|
||||
ga('ec:setAction', 'detail');
|
||||
|
||||
{/literal}
|
||||
{else if isset($page_name) && $page_name == 'order'}
|
||||
{literal}
|
||||
ga('require', 'ec');
|
||||
|
||||
{/literal}
|
||||
{if $step == 0 || $step == 1}
|
||||
{if $cart}
|
||||
{assign var='cartProducts' value=$cart->getProducts()}
|
||||
{foreach from=$cartProducts item=cartProduct}
|
||||
{literal}
|
||||
ga('ec:addProduct', {
|
||||
'id': {/literal}{$cartProduct['id_product']}{literal},
|
||||
'name': "{/literal}{$cartProduct['name']}{literal}",
|
||||
'category': "{/literal}{$cartProduct['category']}{literal}",
|
||||
'price': {/literal}{Tools::ps_round(Product::getPriceStatic((int)$cartProduct['id_product'], true, ((isset($cartProduct['id_product_attribute']) AND !empty($cartProduct['id_product_attribute'])) ? (int)($cartProduct['id_product_attribute']) : NULL), 2), 2)}{literal},
|
||||
'quantity': {/literal}{$cartProduct['cart_quantity']}{literal}
|
||||
});
|
||||
{/literal}
|
||||
{/foreach}
|
||||
{/if}
|
||||
{/if}
|
||||
{literal}
|
||||
|
||||
{/literal}
|
||||
{if $step == 0}{literal}
|
||||
//cart
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 1,
|
||||
});
|
||||
{/literal}
|
||||
{else if $step == 1}{literal}
|
||||
// address
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 2,
|
||||
});
|
||||
{/literal}
|
||||
{else if $step == 2}{literal}
|
||||
// carrier
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 3,
|
||||
});
|
||||
{/literal}
|
||||
{else if $step == 3}{literal}
|
||||
// payment
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 4,
|
||||
});
|
||||
{/literal}
|
||||
{/if}
|
||||
{/if}
|
||||
{literal}
|
||||
|
||||
{/literal}
|
||||
{if isset($page_name) && (($page_name == 'order-confirmation' && $isEC==0) || $page_name != 'order-confirmation')}
|
||||
{literal}
|
||||
// send pageview via header.tpl du module GA si isEC=1 and $page_name == 'order-confirmation'
|
||||
var re = new RegExp("([?&])(email=)[^&#]*", "g");
|
||||
var re2 = new RegExp("([?&])(customer_lastname=)[^&#]*", "g");
|
||||
var re3 = new RegExp("([?&])(customer_firstname=)[^&#]*", "g");
|
||||
if (document.location.href.match(re) || document.location.href.match(re2) || document.location.href.match(re3)) {
|
||||
// remove personal data from url before sending to GA
|
||||
url = window.location.search.replace(re, '$1$2');
|
||||
url = url.replace(re2, '$1$2');
|
||||
url = url.replace(re3, '$1$2');
|
||||
var page = window.location.pathname+url;
|
||||
ga('send', 'pageview', page);
|
||||
} else {
|
||||
ga('send', 'pageview');
|
||||
}
|
||||
{/literal}
|
||||
{/if}
|
||||
{literal}
|
||||
|
||||
function onStepComplete(stepNumber, option, redirect, form) {
|
||||
ga('ec:setAction', 'checkout_option', {
|
||||
'step': stepNumber,
|
||||
'option': option
|
||||
});
|
||||
if (redirect != null) {
|
||||
ga('send', 'event', 'Checkout', 'Option', {
|
||||
hitCallback: function() {
|
||||
document.location = redirect;
|
||||
}
|
||||
});
|
||||
} else if (form != null) {
|
||||
ga('send', 'event', 'Checkout', 'Option', {
|
||||
hitCallback: function() {
|
||||
form.submit();
|
||||
}
|
||||
});
|
||||
} else {
|
||||
ga('send', 'event', 'Checkout', 'Option', {});
|
||||
}
|
||||
}
|
||||
function addToCartToGA(product) {
|
||||
ga('ec:addProduct', {
|
||||
'id': product.id,
|
||||
'name': product.name,
|
||||
'brand': product.category,
|
||||
'category': product.category,
|
||||
'variant' : product.variant,
|
||||
'price': product.price,
|
||||
'quantity': product.qty
|
||||
});
|
||||
ga('ec:setAction', 'add');
|
||||
ga('send', 'event', 'UX', 'click', 'add to cart');
|
||||
}
|
||||
function removeFromCartToGA(product) {
|
||||
ga('ec:addProduct', {
|
||||
'id': product.id,
|
||||
'name': product.name,
|
||||
'brand': product.category,
|
||||
'category': product.category,
|
||||
'variant' : product.variant,
|
||||
'price': product.price,
|
||||
'quantity': product.qty
|
||||
});
|
||||
ga('ec:setAction', 'remove');
|
||||
ga('send', 'event', 'UX', 'click', 'remove to cart');
|
||||
}
|
||||
</script>
|
||||
{/literal}
|
||||
{elseif $cookie->id_lang == 3}
|
||||
{literal}
|
||||
<script>
|
||||
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
|
||||
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
|
||||
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
|
||||
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
|
||||
|
||||
{if isset($facebook_validation) && $facebook_validation}
|
||||
ga('create', 'UA-68580471-1', 'auto');
|
||||
{/literal}
|
||||
{if isset($page_name) && $page_name == 'category'}
|
||||
{literal}
|
||||
ga('require', 'ec');
|
||||
|
||||
{/literal}
|
||||
{else if isset($page_name) && $page_name == 'product'}
|
||||
{literal}
|
||||
ga('require', 'ec');
|
||||
ga('ec:addProduct', {
|
||||
'id': {/literal}{$product->id}{literal},
|
||||
'name': "{/literal}{$product->name|escape:'htmlall':'UTF-8'}{literal}",
|
||||
'category': "{/literal}{$sale->title[$cookie->id_lang]}{literal}"
|
||||
});
|
||||
|
||||
ga('ec:setAction', 'detail');
|
||||
|
||||
{/literal}
|
||||
{else if isset($page_name) && $page_name == 'order'}
|
||||
{literal}
|
||||
ga('require', 'ec');
|
||||
|
||||
{/literal}
|
||||
{if $step == 0 || $step == 1}
|
||||
{if $cart}
|
||||
{assign var='cartProducts' value=$cart->getProducts()}
|
||||
{foreach from=$cartProducts item=cartProduct}
|
||||
{literal}
|
||||
ga('ec:addProduct', {
|
||||
'id': {/literal}{$cartProduct['id_product']}{literal},
|
||||
'name': "{/literal}{$cartProduct['name']}{literal}",
|
||||
'category': "{/literal}{$cartProduct['category']}{literal}",
|
||||
'price': {/literal}{Tools::ps_round(Product::getPriceStatic((int)$cartProduct['id_product'], true, ((isset($cartProduct['id_product_attribute']) AND !empty($cartProduct['id_product_attribute'])) ? (int)($cartProduct['id_product_attribute']) : NULL), 2), 2)}{literal},
|
||||
'quantity': {/literal}{$cartProduct['cart_quantity']}{literal}
|
||||
});
|
||||
{/literal}
|
||||
{/foreach}
|
||||
{/if}
|
||||
{/if}
|
||||
{literal}
|
||||
|
||||
{/literal}
|
||||
{if $step == 0}
|
||||
{literal}
|
||||
//cart
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 1,
|
||||
});
|
||||
{/literal}
|
||||
{else if $step == 1}
|
||||
{literal}
|
||||
// address
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 2,
|
||||
});
|
||||
{/literal}
|
||||
{else if $step == 2}
|
||||
{literal}
|
||||
// carrier
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 3,
|
||||
});
|
||||
{/literal}
|
||||
else if $step == 3}
|
||||
{literal}
|
||||
// payment
|
||||
ga('ec:setAction','checkout', {
|
||||
'step': 4,
|
||||
});
|
||||
{/literal}
|
||||
{/if}
|
||||
{/if}
|
||||
{literal}
|
||||
|
||||
{/literal}
|
||||
{if isset($page_name) && (($page_name == 'order-confirmation' && $isEC==0) || $page_name != 'order-confirmation')}
|
||||
{literal}
|
||||
// send pageview via header.tpl du module GA si isEC=1 and $page_name == 'order-confirmation'
|
||||
var re = new RegExp("([?&])(email=)[^&#]*", "g");
|
||||
var re2 = new RegExp("([?&])(customer_lastname=)[^&#]*", "g");
|
||||
var re3 = new RegExp("([?&])(customer_firstname=)[^&#]*", "g");
|
||||
if (document.location.href.match(re) || document.location.href.match(re2) || document.location.href.match(re3)) {
|
||||
// remove personal data from url before sending to GA
|
||||
url = window.location.search.replace(re, '$1$2');
|
||||
url = url.replace(re2, '$1$2');
|
||||
url = url.replace(re3, '$1$2');
|
||||
var page = window.location.pathname+url;
|
||||
ga('send', 'pageview', page);
|
||||
} else {
|
||||
ga('send', 'pageview');
|
||||
}
|
||||
{/literal}
|
||||
{/if}
|
||||
{literal}
|
||||
|
||||
function onStepComplete(stepNumber, option, redirect, form) {
|
||||
ga('ec:setAction', 'checkout_option', {
|
||||
'step': stepNumber,
|
||||
'option': option
|
||||
});
|
||||
if (redirect != null) {
|
||||
ga('send', 'event', 'Checkout', 'Option', {
|
||||
hitCallback: function() {
|
||||
document.location = redirect;
|
||||
}
|
||||
});
|
||||
} else if (form != null) {
|
||||
ga('send', 'event', 'Checkout', 'Option', {
|
||||
hitCallback: function() {
|
||||
form.submit();
|
||||
}
|
||||
});
|
||||
} else {
|
||||
ga('send', 'event', 'Checkout', 'Option', {});
|
||||
}
|
||||
}
|
||||
function addToCartToGA(product) {
|
||||
ga('ec:addProduct', {
|
||||
'id': product.id,
|
||||
'name': product.name,
|
||||
'brand': product.category,
|
||||
'category': product.category,
|
||||
'variant' : product.variant,
|
||||
'price': product.price,
|
||||
'quantity': product.qty
|
||||
});
|
||||
ga('ec:setAction', 'add');
|
||||
ga('send', 'event', 'UX', 'click', 'add to cart');
|
||||
}
|
||||
function removeFromCartToGA(product) {
|
||||
ga('ec:addProduct', {
|
||||
'id': product.id,
|
||||
'name': product.name,
|
||||
'brand': product.category,
|
||||
'category': product.category,
|
||||
'variant' : product.variant,
|
||||
'price': product.price,
|
||||
'quantity': product.qty
|
||||
});
|
||||
ga('ec:setAction', 'remove');
|
||||
ga('send', 'event', 'UX', 'click', 'remove to cart');
|
||||
}
|
||||
</script>
|
||||
{/literal}
|
||||
{/if}
|
||||
|
||||
<!-- Facebook Pixel Code -->
|
||||
{if $cookie->id_lang == 2}
|
||||
{literal}
|
||||
<script>
|
||||
!function(f,b,e,v,n,t,s){if(f.fbq)return;n=f.fbq=function(){n.callMethod?
|
||||
n.callMethod.apply(n,arguments):n.queue.push(arguments)};if(!f._fbq)f._fbq=n;
|
||||
n.push=n;n.loaded=!0;n.version='2.0';n.queue=[];t=b.createElement(e);t.async=!0;
|
||||
t.src=v;s=b.getElementsByTagName(e)[0];s.parentNode.insertBefore(t,s)}(window,
|
||||
document,'script','//connect.facebook.net/en_US/fbevents.js');
|
||||
|
||||
fbq('init', '585280634957856');
|
||||
fbq('track', "PageView");
|
||||
</script>
|
||||
{/literal}
|
||||
<noscript><img height="1" width="1" style="display:none" src="https://www.facebook.com/tr?id=585280634957856&ev=PageView&noscript=1"/></noscript>
|
||||
{elseif $cookie->id_lang == 3}
|
||||
{literal}
|
||||
<script>
|
||||
!function(f,b,e,v,n,t,s){if(f.fbq)return;n=f.fbq=function(){n.callMethod?
|
||||
n.callMethod.apply(n,arguments):n.queue.push(arguments)};if(!f._fbq)f._fbq=n;
|
||||
n.push=n;n.loaded=!0;n.version='2.0';n.queue=[];t=b.createElement(e);t.async=!0;
|
||||
t.src=v;s=b.getElementsByTagName(e)[0];s.parentNode.insertBefore(t,s)}(window,
|
||||
document,'script','//connect.facebook.net/en_US/fbevents.js');
|
||||
|
||||
fbq('init', '778018572325168');
|
||||
fbq('track', "PageView");
|
||||
</script>
|
||||
{/literal}
|
||||
<noscript><img height="1" width="1" style="display:none" src="https://www.facebook.com/tr?id=778018572325168&ev=PageView&noscript=1"/></noscript>
|
||||
{/if}
|
||||
|
||||
{literal}
|
||||
<script>
|
||||
fbq('track', 'ViewContent', {
|
||||
content_name:'{/literal}{$page_name|escape:'html':'UTF-8'}{literal}'
|
||||
});
|
||||
</script>
|
||||
{/literal}
|
||||
|
||||
{if isset($facebook_validation) && $facebook_validation}
|
||||
{literal}
|
||||
<script>
|
||||
fbq('track', 'CompleteRegistration');
|
||||
</script>
|
||||
{/literal}
|
||||
{/if}
|
||||
|
||||
{if isset($page_name)}
|
||||
{if $page_name == 'order-confirmation'}
|
||||
{literal}
|
||||
<script>
|
||||
fbq('track', 'CompleteRegistration');
|
||||
fbq('track', 'Purchase', {
|
||||
value: '{/literal}{$order->total_paid}{literal}',
|
||||
currency: "{/literal}{$currency['iso_code']}{literal}"
|
||||
});
|
||||
</script>
|
||||
{/literal}
|
||||
{/if}
|
||||
{/if}
|
||||
<!-- End Facebook Pixel Code -->
|
||||
|
||||
{if isset($page_name)}
|
||||
{if $page_name == 'order-confirmation'}
|
||||
{literal}
|
||||
<script>
|
||||
fbq('track', 'Purchase', {
|
||||
value: '{/literal}{$order->total_paid}{literal}',
|
||||
currency: "{/literal}{$currencyIsoCode}{literal}"
|
||||
});
|
||||
</script>
|
||||
{/literal}
|
||||
{/if}
|
||||
{/if}
|
||||
<!-- End Facebook Pixel Code -->
|
||||
|
||||
<!-- crazyegg -->
|
||||
{literal}
|
||||
<script type="text/javascript">
|
||||
setTimeout(function(){var a=document.createElement("script");
|
||||
var b=document.getElementsByTagName("script")[0];
|
||||
a.src=document.location.protocol+"//script.crazyegg.com/pages/scripts/0047/9841.js?"+Math.floor(new Date().getTime()/3600000);
|
||||
a.async=true;a.type="text/javascript";b.parentNode.insertBefore(a,b)}, 1);
|
||||
</script>
|
||||
{/literal}
|
||||
|
||||
{include file="$tpl_dir./header-meta-fb.tpl"}
|
||||
<!-- crazyegg -->
|
||||
{literal}
|
||||
<script type="text/javascript">
|
||||
setTimeout(function(){var a=document.createElement("script");
|
||||
var b=document.getElementsByTagName("script")[0];
|
||||
a.src=document.location.protocol+"//script.crazyegg.com/pages/scripts/0047/9841.js?"+Math.floor(new Date().getTime()/3600000);
|
||||
a.async=true;a.type="text/javascript";b.parentNode.insertBefore(a,b)}, 1);
|
||||
</script>
|
||||
{/literal}
|
||||
|
||||
{include file="$tpl_dir./header-meta-fb.tpl"}
|
||||
</head>
|
||||
|
||||
<body {if $page_name}id="{$page_name|escape:'htmlall':'UTF-8'}"{/if} class="{$bodyClass}{if $cookie->isLogged()} logged{/if}">
|
||||
|
||||
<!--[if lte IE 6]>
|
||||
<div id="ie_notification" style="background: #FFFFE1; border-bottom: 1px solid #A0A0A0; padding: 10px;line-height: 1.4em; text-align: justify;">
|
||||
<strong>{l s='Warning, you are currently using an obsolete browser.'}</strong>
|
||||
{l s='It is a potential source of security breaches and may not display this website properly. Please update your browser to'} <a style="text-decoration: underline;" href="http://windows.microsoft.com/{$lang_iso}-{$lang_iso|strtoupper}/internet-explorer/downloads/ie" onclick="window.open(this.href); return false;">Microsoft Internet Explorer 8</a>.
|
||||
{l s='You can also use an alternative browser, such as'} <a style="text-decoration: underline;" href="http://mozilla-europe.org/{$lang_iso}/" onclick="window.open(this.href); return false;">Mozilla Firefox</a>, <a style="text-decoration: underline;" href="http://www.opera.com/" onclick="window.open(this.href); return false;">Opera</a>, <a style="text-decoration: underline;" href="http://www.google.com/chrome" onclick="window.open(this.href); return false;">Google Chrome</a> {l s='or'} <a style="text-decoration: underline;" href="http://www.apple.com/{$lang_iso}/safari/" onclick="window.open(this.href); return false;">Safari</a>.
|
||||
{l s='These softwares are free. If you don\'t have administrative rights on your computer to install programs, please contact your system administrator.'}
|
||||
</div>
|
||||
<![endif]-->
|
||||
|
||||
<!-- Google Tag Manager (noscript) -->
|
||||
<noscript><iframe src="https://www.googletagmanager.com/ns.html?id=GTM-PT7ZGQF" height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
|
||||
<!-- End Google Tag Manager (noscript) -->
|
||||
<!-- Google Tag Manager (noscript) -->
|
||||
<noscript><iframe src="https://www.googletagmanager.com/ns.html?id=GTM-PT7ZGQF"
|
||||
height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
|
||||
<!-- End Google Tag Manager (noscript) -->
|
||||
|
||||
{if !$content_only}
|
||||
{if isset($restricted_country_mode) && $restricted_country_mode}
|
||||
|
Loading…
Reference in New Issue
Block a user