www.leftshop.top Open in urlscan Pro
2606:4700:3033::6815:1e48  Public Scan

Submitted URL: http://leftshop.top/wp-content/themes/diza/js/ebay/language-currency.js?ver=5.9-alpha-51886
Effective URL: https://www.leftshop.top/wp-content/themes/diza/js/ebay/language-currency.js?ver=5.9-alpha-51886
Submission: On June 07 via api from US — Scanned from DE

Form analysis 0 forms found in the DOM

Text Content

function areaSetLanguageCurrency(language,area)
{let areaLanguageCurrency=getAreaIso2(area);if(areaLanguageCurrency){let languageCode=areaLanguageCurrency.language;let currencyCode=areaLanguageCurrency.currency;if(Array.isArray(languageCode)&&!language){languageCode=languageCode[0];}
if(language){languageCode=language;}
if(languageCode){setCookie("wp_lang",languageCode);}
setCookie("currency",currencyCode);}}
function setLanguageCurrency(language)
{const languages={en:"USD",es:"MXN",fr:"EUR",it:"EUR",nl:"EUR",de:"EUR"}
var currency=languages[language];if(currency){jQuery.ajax({url:'/api/country',type:'get',data:'',async:false,dataType:'json',success:function(res){var country=res.data.country
if(country){let areaCurrency=getAreaIso2(country.iso_code)
if(areaCurrency){currency=areaCurrency.currency}
setCookie("wp_lang",language);setCookie("currency",currency);}}})}}
function getAreaIso2(area)
{const areaISO2={HU:{currency:'HUF',language:''},JP:{currency:'JPY',language:''},NO:{currency:'NOK',language:''},PL:{currency:'PLN',language:''},RU:{currency:'RUB',language:''},SE:{currency:'SEK',language:''},IL:{currency:'ILS',language:''},TH:{currency:'THB',language:''},TW:{currency:'TWD',language:''},MY:{currency:'MYR',language:''},DK:{currency:'DKK',language:''},HK:{currency:'HKD',language:'en'},BR:{currency:'BRL',language:'es'},SG:{currency:'SGD',language:'en'},BO:{currency:'EUR',language:'es'},CR:{currency:'EUR',language:'es'},DO:{currency:'EUR',language:'es'},EC:{currency:'USD',language:'es'},ES:{currency:'EUR',language:'es'},GT:{currency:'EUR',language:'es'},HN:{currency:'EUR',language:'es'},MX:{currency:'MXN',language:'es'},NI:{currency:'EUR',language:'es'},PA:{currency:'EUR',language:'es'},PR:{currency:'USD',language:'es'},PY:{currency:'EUR',language:'es'},SV:{currency:'EUR',language:'es'},VE:{currency:'EUR',language:'es'},AU:{currency:'AUD',language:'en'},BZ:{currency:'USD',language:'en'},CB:{currency:'USD',language:'en'},GB:{currency:'GBP',language:'en'},IE:{currency:'EUR',language:'en'},JM:{currency:'USD',language:'en'},NZ:{currency:'NZD',language:'en'},PH:{currency:'PHP',language:'en'},TT:{currency:'USD',language:'en'},US:{currency:'USD',language:'en'},ZW:{currency:'USD',language:'en'},AT:{currency:'EUR',language:'de'},DE:{currency:'EUR',language:'de'},LI:{currency:'CHF',language:'de'},FR:{currency:'EUR',language:'fr'},MC:{currency:'EUR',language:'fr'},IT:{currency:'EUR',language:'it'},NL:{currency:'EUR',language:'nl'},CA:{currency:'CAD',language:['en','fr']},LU:{currency:'EUR',language:['de','fr']},BE:{currency:'EUR',language:['fr','nl']},CH:{currency:'CHF',language:['de','fr','it']},}
return areaISO2[area];}