function addLoadEvent(t){if(window.jQuery&&window.jQuery(window).on)window.jQuery(window).on("load",t());else if(window.addEventListener)window.addEventListener("load",t,!1);else if(window.attachEvent)window.attachEvent("onload",t);else{var e=window.onload;"function"!=typeof window.onload?window.onload=t:window.onload=function(){e&&e(),t()}}}function set_cookie(t,e,r,n){if(1==n){var i=0,a=document.domain,o=a.split("."),s=escape(e);if(1(new Date).getTime()/1e3),r?(replaceSingleRegexSwitch(e[0],e[1],e[2],e[3]),!0):(nt_analyticsId=e[4],!1)}function loadJSurl(t,e){var r=document.createElement("script");r.src=t;var n=document.getElementsByTagName("head")[0],i=!1;n.appendChild(r),r.onload=r.onreadystatechange=function(){i||this.readyState&&"loaded"!=this.readyState&&"complete"!=this.readyState||(i=!0,e(),r.onload=r.onreadystatechange=null,n.removeChild(r))}}function parseUri(t){var n={strictMode:!0,key:["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"],q:{name:"queryKey",parser:/(?:^|&)([^&=]*)=?([^&]*)/g},parser:{strict:/^(?:([^:\/?#]+):)?(?:\/\/((?:(([^:@]*)(?::([^:@]*))?)?@)?([^:\/?#]*)(?::(\d*))?))?((((?:[^?#\/]*\/)*)([^?#]*))(?:\?([^#]*))?(?:#(.*))?)/,loose:/^(?:(?![^:@]+:[^:@\/]*@)([^:\/?#.]+):)?(?:\/\/)?((?:(([^:@]*)(?::([^:@]*))?)?@)?([^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/}};for(m=n.parser[n.strictMode?"strict":"loose"].exec(t),uri={},i=14;i--;)uri[n.key[i]]=m[i]||"";return uri[n.q.name]={},uri[n.key[12]].replace(n.q.parser,function(t,e,r){e&&(uri[n.q.name][e]=r)}),uri}function getUrlVar(t){t=t.replace(/[\[]/,"\\[").replace(/[\]]/,"\\]");var e=new RegExp("[\\?&]"+t+"=([^&#]*)","i").exec(window.location.href);return null==e?"":e[1]}function getReferrer(){return void 0!==document.referrer?r=document.referrer:r=document.location.href,r}function domIterator(t,e,r,n){for(var i=(n||document.body).childNodes,a=i.length,o=["html","head","style","link","title","meta","script","object","iframe"];a--;){var s=i[a];if(1===s.nodeType){if("A"==s.nodeName&&(s.href.match(/^tel:/)||s.href.match(/\/tel\//)))s.href.replace(t,e)!=s.href&&(s.href.match(/^tel:/)?s.href="tel:+"+e:s.href.match(/\/tel\//)&&(s.href=s.href.replace(/tel\/\+\d{7,16}/i,"tel/+"+e),s.href=s.href.replace(/tel\/\d{7,16}/i,"tel/+"+e)));-1===o.indexOf(s.nodeName.toLowerCase())&&null==s.getAttribute("ninjatrack_ignore")&&arguments.callee(t,e,r,s)}if(null!=s&&3===s.nodeType&&void 0!==s.data){var g=s.data.replace(t,r);g!=s.data&&(parentV=null!=s.parentElement?s.parentElement:s.parentNode,null==parentV||parentV.getAttribute("ninjatrack_orig")||parentV.setAttribute("ninjatrack_orig",encodeURIComponent(s.data)),s.data=g,parentV.setAttribute("ninjatrack_timestamp",(new Date).getTime()))}}}function build_single_number_regex(t){var e=t.replace(/[.?*+^$[\]\\/(){}|-]/g,"\\$&"),r=new Array;if("1"==(t=t.replace(/[\s.?*+^$[\]\\/(){}|-]/g,"")).substring(0,1))var n="",a=t.substring(1,4),o=t.substring(4,7).replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&"),s=t.substring(7).replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&");else n="",a=t.substring(0,3),o=t.substring(3,6).replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&"),s=t.substring(6).replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&");r[0]=n+"\\(\\s?\\u00A0?"+a+"\\s?\\u00A0?\\)[\\-\\.\\s\\u00A0]?"+o+"[\\-\\.\\s\\u00A0]?[\\-\\.\\s\\u00A0]?[\\-\\.\\s\\u00A0]?"+s+"(?!\\d)(?=[<\\s\\u00A0\\.\\!\\?\\,]?)",r[1]=n+a+"\\s?\\u00A0?[\\-\\.\\s\\u00A0]?"+o+"[\\-\\.\\s\\u00A0]?[\\-\\.\\s\\u00A0]?[\\-\\.\\s\\u00A0]?"+s+"(?!\\d)(?=[<\\s\\u00A0\\.\\!\\?\\,]?)",r[2]=n+"("+a+")\\u00A0?\\s?("+o+")\\u00A0?\\s?("+s+")(?!\\d)(?=[<\\s\\u00A0\\.\\!\\?\\,]?)";var g=r.length-1;for(i=0;i<=g;i++)e=e+"|"+r[i];return new RegExp(e,"gi")}function build_single_number_regex_uk(t,e){var r=t.replace(/[.?*+^$[\]\\/(){}|-]/g,"\\$&"),n=(new Array,0);(t=t.replace(/[\s.?*+^$[\]\\/(){}|-\u00A0]/g,"")).substring(0,e.length)==e&&(n=e.length),t.substring(0,e.length+1)=="+"+e&&(n=e.length+1),stringFormat="\\(\\u00A0?\\s?",stringFormat2=" ?\\)?[\\-\\.\\u00A0\\s]?",stringFormat3="[\\-\\.\\u00A0\\s]?",stringFormat4="(?!\\d)";var i=t.substring(n,n+1),a=t.substring(n,n+2),o=t.substring(n,n+3),s=t.substring(n,n+4),g=t.substring(n+1,n+4),m=t.substring(n+2,n+6),u=t.substring(n+2,n+5),c=t.substring(n+3,n+6),l=t.substring(n+4,n+10),d=t.substring(n+3,n+5),_=(t.substring(n+3,n+9),t.substring(n+4,n+9),t.substring(n+4,n+7)),F=t.substring(n+3),p=t.substring(n+4),b=t.substring(n+5),f=t.substring(n+6),h=t.substring(n+7);return r=(r=t.length==n+8?(r=(r=(r=(r=(r=(r=(r=r+"|"+stringFormat+i+stringFormat2+g+stringFormat3+p+stringFormat4)+"|"+i+stringFormat2+g+stringFormat3+p+stringFormat4)+"|"+stringFormat+a+stringFormat2+u+stringFormat3+b+stringFormat4)+"|"+a+stringFormat2+u+stringFormat3+b+stringFormat4)+"|"+stringFormat+o+stringFormat2+F+stringFormat4)+"|"+o+stringFormat2+F+stringFormat4)+"|"+stringFormat+s+stringFormat2+p+stringFormat4)+"|"+s+stringFormat2+p+stringFormat4:t.length==n+9?(r=(r=(r=(r=(r=(r=(r=(r=(r=(r=(r=(r=(r=r+"|"+stringFormat+i+stringFormat2+t.substring(n+1,n+3)+stringFormat3+t.substring(n+3,n+5)+stringFormat3+t.substring(n+5,n+7)+stringFormat3+t.substring(n+7)+stringFormat4)+"|"+i+stringFormat2+t.substring(n+1,n+3)+stringFormat3+t.substring(n+3,n+5)+stringFormat3+t.substring(n+5,n+7)+stringFormat3+t.substring(n+7)+stringFormat4)+"|"+stringFormat+a+stringFormat2+t.substring(n+2,n+5)+stringFormat3+t.substring(n+5,n+7)+stringFormat3+t.substring(n+7)+stringFormat4)+"|"+a+stringFormat2+t.substring(n+2,n+5)+stringFormat3+t.substring(n+5,n+7)+stringFormat3+t.substring(n+7)+stringFormat4)+"|"+stringFormat+a+stringFormat2+u+stringFormat3+b+stringFormat4)+"|"+a+stringFormat2+u+stringFormat3+b+stringFormat4)+"|"+stringFormat+o+stringFormat2+d+stringFormat3+b+stringFormat4)+"|"+o+stringFormat2+d+stringFormat3+b+stringFormat4)+"|"+stringFormat+o+stringFormat2+c+stringFormat3+f+stringFormat4)+"|"+o+stringFormat2+c+stringFormat3+f+stringFormat4)+"|"+stringFormat+o+stringFormat2+F+stringFormat4)+"|"+o+stringFormat2+F+stringFormat4)+"|"+stringFormat+s+stringFormat2+p+stringFormat4)+"|"+s+stringFormat2+p+stringFormat4:(r=(r=(r=(r=(r=(r=(r=(r=(r=(r=(r=r+"|"+stringFormat+a+stringFormat2+t.substring(n+2,n+4)+stringFormat3+t.substring(n+4,n+6)+stringFormat3+t.substring(n+6,n+8)+stringFormat3+t.substring(n+8)+stringFormat4)+"|"+a+stringFormat2+t.substring(n+2,n+4)+stringFormat3+t.substring(n+4,n+6)+stringFormat3+t.substring(n+6,n+8)+stringFormat3+t.substring(n+8)+stringFormat4)+"|"+stringFormat+a+stringFormat2+m+stringFormat3+f+stringFormat4)+"|"+a+stringFormat2+m+stringFormat3+f+stringFormat4)+"|"+stringFormat+a+stringFormat2+u+stringFormat3+b+stringFormat4)+"|"+a+stringFormat2+u+stringFormat3+b+stringFormat4)+"|"+stringFormat+o+stringFormat2+c+stringFormat3+f+stringFormat4)+"|"+o+stringFormat2+c+stringFormat3+f+stringFormat4)+"|"+stringFormat+s+stringFormat2+p+stringFormat4)+"|"+s+stringFormat2+l+stringFormat4)+"|"+stringFormat+s+stringFormat2+_+stringFormat3+h+stringFormat4)+"|"+s+stringFormat2+_+stringFormat3+h+stringFormat4)+"|"+t.substring(n),new RegExp(r,"gi")}function replaceSingleRegexSwitch(t,e,r,n){switch(n){case"te":replaceSingleRegex_test(t,e,r);break;case"GB":replaceSingleRegex_alt(t,e,r,"44");break;case"IE":replaceSingleRegex_alt(t,e,r,"353");break;case"AU":replaceSingleRegex_alt(t,e,r,"61");break;case"NZ":replaceSingleRegex_alt(t,e,r,"64");break;case"FR":replaceSingleRegex_alt(t,e,r,"33");break;case"DE":replaceSingleRegex_alt(t,e,r,"49");break;case"IT":replaceSingleRegex_alt(t,e,r,"39");break;case"CL":replaceSingleRegex_alt(t,e,r,"56");case"CH":replaceSingleRegex_alt(t,e,r,"41");case"HK":replaceSingleRegex_alt(t,e,r,"852");case"AR":replaceSingleRegex_alt(t,e,r,"54");break;default:replaceSingleRegex(t,e,r)}}function replaceSingleRegex_test(t,e,r){0!=t.length&&domIterator(t,e,r,null)}function replaceSingleRegex(t,e,r){if(0!=(t=t.trim()).length){var n=build_single_number_regex(t);"1 "==r.substring(0,2)?r=r.substring(2):"1"==r.substring(0,1)&&(r=r.substring(1)),"+"==e.substring(0,1)&&(e=e.substring(1)),domIterator(n,e,r,null)}}function replaceSingleRegex_alt(t,e,r,n){if(0!=(t=t.trim()).length){var i=build_single_number_regex_uk(t,n);r.substring(0,n.length+1)==n+" "?r=r.substring(n.length+1):r.substring(0,n.length)==n&&(r=r.substring(n.length)),"+"==e.substring(0,1)&&(e=e.substring(1)),domIterator(i,e,r,null)}}addLoadEvent(function(){getReplacementNumber()}),window.jQuery&&window.jQuery(document).on&&(window.jQuery(document).on("pagebeforeshow",function(t,e){getReplacementNumber()}),window.jQuery(document).on("pagecontainerbeforetransition",function(t,e){getReplacementNumber()}));