AVVISO

L’utente potrebbe incorrere in un malfunzionamento del sito o in visualizzazioni errate delle pagine se non ha accettato tutti i cookie. Se si riscontrano problemi, suggeriamo di cliccare in basso a destra su logo verde e accettare i relativi cookie.

Chi Siamo

Inspirata alle vecchie barberie siciliane, Old Barber diventa negli anni un'azienda affermata e specializzata nella produzione e distribuzione internazionale di cosmetici mschili di alta qualità, rigorosamente 100% Made in Italy.

Old Barber

Qualità Italiana nel Mondo della Cosmetica

Newsletter

Logo Old Barber

©2022 Magoddo srl – P.IVA 16116751005

", overlaySpinner = "
", overlayTitle = "

" + _localizedStrings.redirect_overlay_title + "

", overlayText = "

" + _localizedStrings.redirect_overlay_text + "

"; switch (_redirectOverlay) { case "overlay-only": break; case "overlay-with-spinner": overlayHTML = overlayContainer + overlaySpinner + overlayContainerClose; break; default: overlayHTML = overlayContainer + overlaySpinner + overlayTitle + overlayText + overlayContainerClose; break; } overlay.insertAdjacentHTML("afterbegin", overlayHTML); document.body.appendChild(overlay); } window.location = url; }; var targetWindow = _targetWindow || 'prefer-popup', lastPopup = false; var buttonLinks = document.querySelectorAll(' a[data-plugin="nsl"][data-action="connect"], a[data-plugin="nsl"][data-action="link"]'); buttonLinks.forEach(function (buttonLink) { buttonLink.addEventListener('click', function (e) { if (lastPopup && !lastPopup.closed) { e.preventDefault(); lastPopup.focus(); } else { var href = this.href, success = false; if (href.indexOf('?') !== -1) { href += '&'; } else { href += '?'; } var redirectTo = this.dataset.redirect; if (redirectTo === 'current') { href += 'redirect=' + encodeURIComponent(window.location.href) + '&'; } else if (redirectTo && redirectTo !== '') { href += 'redirect=' + encodeURIComponent(redirectTo) + '&'; } if (targetWindow !== 'prefer-same-window' && checkWebView()) { targetWindow = 'prefer-same-window'; } if (targetWindow === 'prefer-popup') { lastPopup = NSLPopup(href + 'display=popup', 'nsl-social-connect', this.dataset.popupwidth, this.dataset.popupheight); if (lastPopup) { success = true; e.preventDefault(); } } else if (targetWindow === 'prefer-new-tab') { var newTab = window.open(href + 'display=popup', '_blank'); if (newTab) { if (window.focus) { newTab.focus(); } success = true; window._nslHasOpenedPopup = true; e.preventDefault(); } } if (!success) { window.location = href; e.preventDefault(); } } }); }); let hasWebViewLimitation = false; var googleLoginButtons = document.querySelectorAll(' a[data-plugin="nsl"][data-provider="google"]'); if (googleLoginButtons.length && checkWebView()) { googleLoginButtons.forEach(function (googleLoginButton) { googleLoginButton.remove(); hasWebViewLimitation = true; }); } var facebookLoginButtons = document.querySelectorAll(' a[data-plugin="nsl"][data-provider="facebook"]'); if (facebookLoginButtons.length && checkWebView() && /Android/.test(window.navigator.userAgent) && !isAllowedWebViewForUserAgent('facebook')) { facebookLoginButtons.forEach(function (facebookLoginButton) { facebookLoginButton.remove(); hasWebViewLimitation = true; }); } const separators = document.querySelectorAll('div.nsl-separator'); if (hasWebViewLimitation && separators.length) { separators.forEach(function (separator) { let separatorParentNode = separator.parentNode; if (separatorParentNode) { const separatorButtonContainer = separatorParentNode.querySelector('div.nsl-container-buttons'); if (separatorButtonContainer && !separatorButtonContainer.hasChildNodes()) { separator.remove(); } } }) } }); /** * Cross-Origin-Opener-Policy blocked the access to the opener */ if (typeof BroadcastChannel === "function") { const _nslLoginBroadCastChannel = new BroadcastChannel('nsl_login_broadcast_channel'); _nslLoginBroadCastChannel.onmessage = (event) => { if (window?._nslHasOpenedPopup && event.data?.action === 'redirect') { window._nslHasOpenedPopup = false; const url = event.data?.href; _nslLoginBroadCastChannel.close(); if (typeof window.nslRedirect === 'function') { window.nslRedirect(url); } else { window.opener.location = url; } } }; }})();