1var countryCodeCookieName="currencyCode";$(function(){$('#currencySelector li').click(function(){clickLanguageSelector($(this))});setCurrencyCookieBasedOnIp()});function clickLanguageSelector(listItem){var format=getActiveCurrencyFormat(listItem);if(listItem.parents('.plagiarism').length>0){switchPlagiarismPrices(format)} 2if(listItem.parents('.proofreading').length>0){setProofreadingCurrency(listItem.data());if(typeof update_price==='function'){update_price(!0)} 3updatePriceShortcodes()} 4currencyCodeToCookie(listItem.data("currencycode"));$("#currencySelector li").removeClass("dropdown__item--active");listItem.addClass("dropdown__item--active");const newLocal=$('#changeCurrencyButton').data('change-text');if(newLocal=='change'){$('#changeCurrencyButton').text(listItem.data('symbol')+' '+listItem.data('currencycode'))}} 5function setProofreadingCurrency(dataAttributes){$.each(dataAttributes,function(attribute,value){$("#priceCalculator,body").data(attribute,value)})} 6function switchPlagiarismPrices(currencyFormat){$("#smallDocument .total-price").html(formatPrices(currencyFormat,plagiarismPrices.small[currencyFormat.currencyCode]));$("#mediumDocument .total-price").html(formatPrices(currencyFormat,plagiarismPrices.medium[currencyFormat.currencyCode]));$("#bigDocument .total-price").html(formatPrices(currencyFormat,plagiarismPrices.big[currencyFormat.currencyCode]));$(".total-price").highlight(1000)} 7jQuery.fn.highlight=function(delay){$(this).each(function(){var el=$(this);el.before("<"+el[0].localName+"/>");el.prev().width(el.width()).height(el.height()).css({"position":"absolute","background-color":"#ffff99","opacity":".9","border-radius":"3px"}).fadeOut(delay)})} 8function formatPrices(currencyFormat,amount,decimals){decimals=typeof decimals!=='undefined'?decimals:2;if(amount.toString().indexOf(".")==-1){decimals=0} 9if(decimals==3){if(Math.round(amount*100)*10-Math.round(amount*1000)==0){decimals=2}} 10return accounting.formatMoney(amount,currencyFormat.symbol,decimals,currencyFormat.thousandSep,currencyFormat.decimalSep,currencyFormat.format).replace(' ',' ')} 11function getActiveCurrencyFormat(newCurrency){return{thousandSep:newCurrency.data("thousandsep"),decimalSep:newCurrency.data("decimalsep"),currencyCode:newCurrency.data("currencycode"),symbol:newCurrency.data("symbol"),format:newCurrency.data("format")}} 12function setCurrencyCookieBasedOnIp(){if(Cookies.get(countryCodeCookieName)===undefined){var ignoreGeoToCountry={"nl":"EUR","es":"EUR","da":"DKK","nb":"NOK","sv":"SEK","fr":"EUR"};if(ignoreGeoToCountry[siteLang]===undefined){doAjaxGeoToCountry()}else{currencyCodeToCookie(ignoreGeoToCountry[siteLang]);changeCurrencyAfterCookie()}}else{changeCurrencyAfterCookie()}} 13function doAjaxGeoToCountry(){jQuery.ajax({url:rootUrl+'/geolookup',type:'POST',dataType:'json',success:function(countryCode){if(location!="{}"){currencyCodeToCookie(getCurrencyBasedOnCountryCode(countryCode));changeCurrencyAfterCookie()}else{currencyCodeToCookie("NA");changeCurrencyAfterCookie()}},error:function(){currencyCodeToCookie("NA");changeCurrencyAfterCookie()}})} 14function changeCurrencyAfterCookie(){var currencyCode=Cookies.get(countryCodeCookieName);var listItem=$("#currencySelector li[data-currencycode='"+currencyCode+"']");if(listItem.length>=1){listItem.click()}} 15function getCurrencyBasedOnCountryCode(countryCode){var countryToCurrencyCode={"US":"USD","UK":"GBP","CA":"CAD","AU":"AUD","CH":"CHF","BR":"BRL","DK":"DKK","SE":"SEK","FI":"EUR","NO":"NOK","CN":"CNY","JP":"JPY","NL":"EUR","DE":"EUR","AT":"EUR","BE":"EUR","IE":"EUR","GR":"EUR","PT":"EUR","FR":"EUR","ES":"EUR","IT":"EUR"};if(countryToCurrencyCode[countryCode]===undefined){return"NA"}else{return countryToCurrencyCode[countryCode]}} 16function currencyCodeToCookie(currencyCode){Cookies.set(countryCodeCookieName,currencyCode,{expires:60,path:'/',domain:getRootDomain()})} 17function updatePriceShortcodes(){var currencyFormat=getActiveCurrencyFormat($('body'));$('#price-calculator [data-type="pricePerWord"]').each(function(){var servicelevel=$(this).data('servicelevel');var deadline=parseInt($(this).data('deadline'));var words=parseInt($(this).data('words'));var services=$(this).data('services').split(',');var pricePerWord=0;$.each(services,function(index,service){if(service=='setup'){pricePerWord+=proofreadingPrices[servicelevel][service][currencyFormat.currencyCode]}else{pricePerWord+=proofreadingPrices[servicelevel][service][deadline][currencyFormat.currencyCode]*words}});if(pricePerWord>20){pricePerWord=Math.round(pricePerWord)} 18$(this).html(formatPrices(currencyFormat,pricePerWord,3))});$('[data-type="setupFee"]').each(function(){$(this).html(formatPrices(currencyFormat,proofreadingPrices.regular.setup[currencyFormat.currencyCode],0))});$('[data-type="layoutPrice"]').each(function(){$(this).html(formatPrices(currencyFormat,proofreadingPrices.regular.layout[7][currencyFormat.currencyCode],2))});$('[data-type="referencePrice"]').each(function(){$(this).html(formatPrices(currencyFormat,proofreadingPrices.regular.reference[7][currencyFormat.currencyCode],2))})}
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.