function General(){};General.trimAll=function(sString){if(sString.length==0)return'';while(sString.substring(0,1)==' ')sString=sString.substring(1,sString.length);while(sString.substring(sString.length-1,sString.length)==' ')sString=sString.substring(0,sString.length-1);return sString;};General.isEmail=function(login){if(!login.match(/^[a-zA-Z\._\-0-9]{1,}@[a-zA-Z0-9\-_\.]{1,}\.[a-zA-Z]{2,}$/))return false;return true;};General.isKey=function(serial_str){if(!serial_str.match(/^[a-fA-F0-9\- ]{20,}$/)&&!serial_str.match(/^[a-zA-Z0-9\- ]{7,}$/))return false;return true;};General.isNumeric=function(sText){if(sText.length==0)return false;var ValidChars="0123456789";var Char;var i;for(i=0;i<sText.length;i++){Char=sText.charAt(i);if(ValidChars.indexOf(Char)==-1)return false;};return true;};General.isReal=function(sText){if(sText.length==0)return false;var ValidChars="0123456789.";var Char;var i;for(i=0;i<sText.length;i++){Char=sText.charAt(i);if(ValidChars.indexOf(Char)==-1)return false;};return true;};General.DaysArray=function(n){for(var i=1;i<=n;i++){this[i]=31;if(i==4||i==6||i==9||i==11){this[i]=30;};if(i==2){this[i]=29;};};return this;};General.daysInFebruary=function(year){return(((year%4==0)&&((!(year%100==0))||(year%400==0)))?29:28);};General.checkDate=function(day,month,year){nrDays=General.DaysArray(12);if(month==2&&day>General.daysInFebruary(year))return false;if(day>nrDays[month])return false;return true;};General.OpenScanWindow=function(url,name){var day=new Date();var parameters='';var pageName=name?name:day.getTime();if(screen.height<525)parameters='scrollbars=yes,status=no,width=746,height=525,menubar=no,left=50,top=50,location=no,resizable=no,directories=no';else parameters='scrollbars=no,status=no,width=746,height=525,menubar=no,left=50,top=50,location=no,resizable=no,directories=no';eval("bitdefender"+pageName+" = window.open('"+url+"','"+pageName+"','"+parameters+"')");if(eval("bitdefender"+pageName)&&window.focus)eval("bitdefender"+pageName).focus();};General.CheckSearchForm=function(form){var query=form.elements["query"].value;if(query.length<3){alert("Search Query is too short.");return false;};if(query=="enter query here ..."){alert("Please enter your search query.");return false;};return true;};General.GetCookie=function(name){var start=document.cookie.indexOf(name+"=");var len=start+name.length+1;if((!start)&&(name!=document.cookie.substring(0,name.length)))return null;if(start==-1)return null;var end=document.cookie.indexOf(";",len);if(end==-1)end=document.cookie.length;return unescape(document.cookie.substring(len,end));};General.SetCookie=function(name,value,expires2,path,domain){var expires=new Date();expires.setTime(expires.getTime()+24*60*60*90*1000);document.cookie=name+"="+escape(value)+"; expires=0"+((path)?"; path="+path:"")+((domain)?"; domain="+domain:"");};General.DeleteCookie=function(name,path,domain){if(General.GetCookie(name))document.cookie=name+"="+((path)?";path="+path:"")+((domain)?";domain="+domain:"")+";expires=Thu, 01-Jan-70 00:00:01 GMT";};General.str_replace=function(search,replace,subject){var temp=subject.split(search);return temp.join(replace);};General.setReferenceID=function(buttonID){return true;var referenceID=General.GetCookie("referenceID");var buyOnlineLink=document.getElementById(buttonID);if(!buyOnlineLink.href.match('digitalriver'))return false;if(buyOnlineLink.href.match('referenceID'))return false;if(referenceID==null||referenceID.length!=32)return false;var lastChar=buyOnlineLink.href.substring(buyOnlineLink.href.length-1,buyOnlineLink.href.length);if(lastChar!="/")buyOnlineLink.href=buyOnlineLink.href+"/";buyOnlineLink.href=buyOnlineLink.href+"referenceID."+referenceID;return true;};function popUpPage(url,parameters,name){var day=new Date();var pageName=name?name:day.getTime();eval("bitdefender"+pageName+" = window.open('"+url+"','"+pageName+"','"+parameters+"')");if(eval("bitdefender"+pageName)&&window.focus)eval("bitdefender"+pageName).focus();};function formCheckAdminModifyAccount(form){var status=form.elements["nfo[user_status]"].value;var status_actual=form.elements["nfo[user_status_actual]"].value;var message=form.elements["nfo[user_message]"].value;if(status!=status_actual&&message==""){alert("Please write a message to user.");return false;};return true;};function SwitchMenu(obj){if(document.getElementById){var el=document.getElementById(obj);var ar=document.getElementById("cont").getElementsByTagName("DIV");if(el.style.display=="none"){for(var i=0;i<ar.length;i++){ar[i].style.display="none";};el.style.display="block";}else {el.style.display="none";};};};function ShowDate(){this_month=new Array("January","February","March","April","May","June","July","August","September","October","November","December");var today=new Date();var day=today.getDate();var month=today.getMonth();var year=today.getYear();if(year<1900){year+=1900;};return(this_month[month]+" "+day+", "+year);};function ShowDateRo(){this_month=new Array("Ianuarie","Februarie","Martie","Aprilie","Mai","Iunie","Iulie","August","Septembrie","Octombrie","Noiembrie","Decembrie");var today=new Date();var day=today.getDate();var month=today.getMonth();var year=today.getYear();if(year<1900){year+=1900;};return(day+" "+this_month[month]+" "+year);};var countrySelect_URLs=new Array();countrySelect_URLs[0]="http://www1.bitdefender.com/site/";countrySelect_URLs[1]="http://www1.bitdefender.fr/site/";countrySelect_URLs[2]="http://www1.bitdefender.de/site/";countrySelect_URLs[3]="http://www1.bitdefender.ro/site/";countrySelect_URLs[4]="http://www1.bitdefender.es/site/";countrySelect_URLs[5]="http://www1.bitdefender.com/en/";function jumpToURL(formName,menuName){var obj=document.getElementById("countrySelect");var index=obj.selectedIndex;var url=eval(menuName+"_URLs["+index+"]")+formName;document.title=url;location.href=url;};function setCookie(name,value,expires2,path,domain){var expires=new Date();expires.setTime(expires.getTime()+24*60*60*90*1000);document.cookie=name+"="+escape(value)+((expires)?"; expires="+expires.toGMTString():"")+((path)?"; path="+path:"")+((domain)?"; domain="+domain:"");};General.getSEOInfo=function(form,BASE_URI,title_id,description_id){var fromTitle=document.getElementById(title_id);var fromDescription=document.getElementById(description_id);var fromContent=document.getElementById('content');var fromKeywords=General.getKeywords(fromContent.value+fromTitle.value+fromDescription.value);var title=document.getElementById("seo_title");var description=document.getElementById("seo_description");var keywords=document.getElementById("seo_keywords");title.value=fromTitle.value;description.value=fromDescription.value;keywords.value=fromKeywords;return true;};General.getKeywords=function(text){text=text.replace(/;/g,' ');text=text.replace(/:/g,' ');text=text.replace(/\./g,' ');text=text.replace(/-/g,' ');text=text.replace(/\,/g,' ');text=text.replace(/\?/g,' ');var keyword_array=text.split(" ");var new_arr=new Array();var keywords_string="";var i=0;var counter=1;var element="";var next_element="";var common_words_string=common_words.join("--");for(n=0;n<keyword_array.length;n++){element=keyword_array[n];if(element.match(/^[a-zA-Z_\-0-9]{3,}$/)&&(common_words_string.lastIndexOf(element.toLowerCase())==-1)){if(n!=keyword_array.length)next_element=keyword_array[n+1];else next_element="zzzzzzzzzzzzzz";if(next_element!=element){new_arr[i]=new Array();new_arr[i][1]=element;new_arr[i][2]=counter;element=keyword_array[n+1];i++;counter=1;}else {if(counter<50)counter++;};}else element=keyword_array[n+1];};for(i=0;i<new_arr.length;i++){var temp=new_arr[i];if(temp[2]>=3||1==1){keywords_string=keywords_string+temp[1]+",";};};if(keywords_string.length>3){keywords_string=keywords_string.slice(0,keywords_string.length-1);};return keywords_string;};function EnableStates(value){if(value==2){document.getElementById('state_sel').style.display='block';document.getElementById('state_sel1').style.display='block';document.getElementById('city').style.display='block';document.getElementById('city_mall').style.display='block';}else{document.getElementById('state_sel').style.display='none';document.getElementById('state_sel1').style.display='none';document.getElementById('city').style.display='none';document.getElementById('city_mall').style.display='none';};};General.getXMLHttpRequestObject=function(){var xmlobj;if(xmlobj!=null&&xmlobj.readyState!=0&&xmlobj.readyState!=4){xmlobj.abort();};try{xmlobj=new XMLHttpRequest();}catch(e){try{xmlobj=new ActiveXObject('Microsoft.XMLHTTP');}catch(e){xmlobj=null;return false;};};return xmlobj;};General.getUrlVars=function(){var vars=[],hash;var hashes=window.location.href.slice(window.location.href.indexOf('?')+1).split('&');for(var i=0;i<hashes.length;i++){hash=hashes[i].split('=');vars.push(hash[0]);vars[hash[0]]=hash[1];};return vars;};General.in_array=function(array,val){for(i=0;i<array.length;i++){if(array[i]==val)return i;};return-1;};General.trackQuickRenew=function(buttonID){var buyOnlineLink=document.getElementById(buttonID);if(buyOnlineLink.href.match('upSellGate')||buyOnlineLink.href.match('upsellDe')){var lastChar=buyOnlineLink.href.substring(buyOnlineLink.href.length-1,buyOnlineLink.href.length);if(lastChar!="/")buyOnlineLink.href=buyOnlineLink.href+"/";buyOnlineLink.href=buyOnlineLink.href+"qr/"};if(buyOnlineLink.href.match('store.bitdefender.com')||buyOnlineLink.href.match('avangate.com')){if(buyOnlineLink.href.indexOf('?')>0)buyOnlineLink.href=buyOnlineLink.href+"&SRC=RENEW_QUICK&REF=RENEW_QUICK";else buyOnlineLink.href=buyOnlineLink.href+"?SRC=RENEW_QUICK&REF=RENEW_QUICK";};return true;};function FixedLayerManager(id){this.id=id;this.timeout=null;this.layers=new Array();};FixedLayerManager.prototype.showLayers=function(){for(i=0;i<this.layers.length;i++)this.layers[i].domLayer.style.visibility='visible';};FixedLayerManager.prototype.hideLayers=function(){if(this.timeout!=null){clearTimeout(this.timeout);this.timeout=null;};for(i=0;i<this.layers.length;i++)this.layers[i].domLayer.style.visibility='hidden';};FixedLayerManager.prototype.repositionLayers=function(){for(i=0;i<this.layers.length;i++){this.layers[i].domLayer.style.top=this.layers[i].originalTop +document.body.scrollTop;this.layers[i].domLayer.style.left=this.layers[i].originalLeft +document.body.scrollLeft;};};FixedLayerManager.prototype.addLayers=function(){if(arguments.length==0)return;var args=(arguments[0]instanceof Array)?arguments[0]:arguments;for(var i=0;i<args.length;i++){var domLayer=(typeof(args[i])=='object')?args[i]:document.getElementById(args[i]);if(domLayer==null){throw('ERROR: Argument #'+i+' ('+args[i]+') in call to '+this.id+'.addLayers('+args.join(', ')+') is not an object or valid element ID.');};var layer=new Array();layer['domLayer']=domLayer;layer['originalTop']=domLayer.offsetTop;layer['originalLeft']=domLayer.offsetLeft;this.layers.push(layer);};};FixedLayerManager.prototype.init=function(){if(navigator.userAgent.match(/msie/i)==null)return false;window.onscroll=new Function(this.id+'.onScrollHandler();');this.addLayers.apply(this,arguments);return true;};FixedLayerManager.prototype.onScrollHandler=function(){if(this.timeout==null)this.hideLayers();else {clearTimeout(this.timeout);this.timeout=null;};this.repositionLayers();this.timeout=setTimeout(this.id+'.showLayers();'+this.id +'.timeout = null;',this.ONSCROLL_HANDLER_DELAY);};FixedLayerManager.prototype.ONSCROLL_HANDLER_DELAY=200;var css_browser_selector=function(){var ua=navigator.userAgent.toLowerCase();var is=function(t){return ua.indexOf(t)!=-1;};var h=document.getElementsByTagName('html')[0];var b=(!(/opera|webtv/i.test(ua))&&/msie (\d)/.test(ua))?('ie ie'+RegExp.$1):is('gecko/')?'gecko':is('opera/9')?'opera opera9':/opera (\d)/.test(ua)?'opera opera'+RegExp.$1:is('konqueror')?'konqueror':is('applewebkit/')?'webkit safari':is('mozilla/')?'gecko':'';var os=(is('x11')||is('linux'))?' linux':is('mac')?' mac':is('win')?' win':'';var c=b+os+' js';if(longwords==1){var c=b+os+' js'+' longwords';};h.className+=h.className?' '+c:c;}();var languages=new Array();var languages_countries=new Array();var languagesURLs=new Array();languages['latin']="Am&#233;rica Latina - Espa&#241;ol";languages['au']="Australia - English";languages['be1']="Belgique - Français";languages['be2']="België - Nederlands";languages['br']="Brasil - Portugu&#234;s";languages['de']="Deutschland - Deutsch";languages['es']="Espa&#241;a- Espa&#241;ol";languages['fr']="France - Fran&#231;ais";languages['in']="India - English";languages['it']="Italy - Italian";languages['me']="&#1575;&#1604;&#1593;&#1585;&#1576;&#1610;&#1577;";languages['nl']="Nederland - Nederlands";languages['pt']="Portugal - Portugu&#234;s";languages['ro']="Rom&acirc;nia - Rom&acirc;n&atilde;";languages['se']="Sweden - Svensk";languages['en']="United States - English";languages['uk']="United Kingdom - English";languages['world']="WorldWide - English";languages_countries['latin']="América Latina";languages_countries['au']="Australia";languages_countries['be1']="Belgique";languages_countries['be2']="België";languages_countries['br']="Brasil";languages_countries['de']="Deutschland";languages_countries['es']="España";languages_countries['fr']="France";languages_countries['in']="India";languages_countries['it']="Italy";languages_countries['me']="&#1575;&#1604;&#1593;&#1585;&#1576;&#1610;&#1577;";languages_countries['nl']="Nederland";languages_countries['pt']="Portugal";languages_countries['ro']="România";languages_countries['se']="Sweden";languages_countries['en']="United States";languages_countries['uk']="United Kingdom";languages_countries['ru']="&#1056;&#1086;&#1089;&#1089;&#1080;&#1103; &#1080; &#1057;&#1053;&#1043;";languages_countries['world']="WorldWide";languagesURLs['latin']="http://www.bitdefender.com/latin/";languagesURLs['au']="http://www.bitdefender.com.au/";languagesURLs['be1']="http://www.bitdefender.fr/";languagesURLs['be2']="http://www.bitdefender.nl/";languagesURLs['br']="http://www.bitdefender.com/br/";languagesURLs['de']="http://www.bitdefender.de/";languagesURLs['es']="http://www.bitdefender.es/";languagesURLs['fr']="http://www.bitdefender.fr/";languagesURLs['in']="http://www.bitdefender.in";languagesURLs['it']="http://www.bitdefender.it/";languagesURLs['ro']="http://www.bitdefender.ro/";languagesURLs['me']="http://www.bitdefenderme.com/";languagesURLs['nl']="http://www.bitdefender.com/nl/";languagesURLs['pt']="http://www.bitdefender.pt";languagesURLs['en']="http://www.bitdefender.com/";languagesURLs['uk']="http://www.bitdefender.co.uk";languagesURLs['se']="http://www.bitdefender.se/";languagesURLs['world']="http://www.bitdefender.com/world/";var planguages=new Array();var planguagesURLs=new Array();planguages['cn']="China - ADH - &#20225;&#19994;&#21644;OEM&#29256;";planguages['cnh']="China - Ruanda - &#20010;&#20154;&#29256;";planguages['hr']="Croatia - Hrvatski";planguages['dk']="Denmark - Danish";planguages['jp']="Japan - &#26085;&#26412;&#35486;";planguages['mx']="Mexico - Espa&#241;ol";planguages['nz']="New Zealand - English";planguages['ru']="&#1056;&#1086;&#1089;&#1089;&#1080;&#1103; &#1080; &#1057;&#1053;&#1043; - &#1056;&#1091;&#1089;&#1089;&#1082;&#1080;&#1081;";planguages['si']="Slovenija - Sloven&#353;&#269;ina";planguages['za']="South Africa - English";planguages['tw']="Taiwan - Traditional Chinese";planguagesURLs['hr']="http://www.bitdefender.hr/";planguagesURLs['mx']="http://www.bitdefender.com.mx/";planguagesURLs['nz']="http://www.bitdefender.co.nz/";planguagesURLs['si']="http://www.bitdefender.si/";planguagesURLs['ru']="http://www.bitdefender.ru";planguagesURLs['za']="http://www.bitdefender.co.za/";planguagesURLs['tw']="http://www.bitdefender.com.tw/";planguagesURLs['cn']="http://www.bitdefender-cn.com/";planguagesURLs['cnh']="http://www.bit361.com/";planguagesURLs['jp']="http://www.bitdefender.jp/";planguagesURLs['dk']="http://bitdefender.itgration.dk/";function jumpCountryToURL(form,document){var country_id=document.getElementById('country_id').value;if(languagesURLs[country_id]==undefined){if(planguagesURLs[country_id]==undefined)window.location.href="http://www.bitdefender.com/world/";else window.location.href=planguagesURLs[country_id];}else window.location.href=languagesURLs[country_id];};function showCountries2(container_id){var jContainer=$("#"+container_id);if(jContainer==null)return;jContainer.hide();var jImg=$(document.createElement('img')).attr('width','18').attr('height','12').attr('valign','absmiddle').attr('src','/images/flags/'+multilang_js['DEFAULT_LANGUAGE']+'.gif');var jSelector=$(document.createElement('select')).attr('id','country_id').attr('name','country_id').css('display','inline').addClass('input_edit');jSelector.bind('change',function(){jumpCountryToURL(this,document);});for(var i in languages){var decoded=$('<div/>').html(languages[i]).text();$(jSelector).append($(document.createElement("option")).attr("value",i).text(decoded));};$(jSelector).append($(document.createElement("option")).attr("value",'us').text(' ------------------------------------ ')).append($(document.createElement("option")).attr("value","us").text(' - Partners Websites - ')).append($(document.createElement("option")).attr("value","us").text(' ------------------------------------ '));for(var i in planguages){var decoded=$('<div/>').html(planguages[i]).text();$(jSelector).append($(document.createElement("option")).attr("value",i).text(decoded));};jContainer.append(jImg);jContainer.append(jSelector);jContainer.show();};function showCountries(){document.write('<img src="/images/flags/'+multilang_js['DEFAULT_LANGUAGE']+'.gif" width="18" height="12" valign="absmiddle">&nbsp;');document.write('<select id="country_id" class="input_edit" style="display:inline" name="country_id" onChange="jumpCountryToURL(this,document);">');for(var i in languages){document.write('<option value="'+i+'"');if(i==multilang_js['DEFAULT_LANGUAGE']){document.write(' SELECTED ');};document.write('>'+languages[i]+'</option>');};document.write('<option value="us"> ------------------------------------ </option>');document.write('<option value="us"> - Partners Websites - </option>');document.write('<option value="us"> ------------------------------------ </option>');for(var j in planguages){document.write('<option value="'+j+'">'+planguages[j]+'</option>');};document.write('</select>');};function showCountriesWorking(){var output='';output+='<select id="country_id" class="input_edit" style="display:inline" name="country_id" onChange="jumpCountryToURL(this,document);">';for(var i in languages){output+='<option value="'+i+'"';if(i==multilang_js['DEFAULT_LANGUAGE']){output+=' SELECTED ';try {$(".menu_country").attr("title",languages_countries[i]);$(".menu_country").html(languages_countries[i]);}catch(err){};};output+='>'+languages[i]+'</option>';};output+='<option value="us"> ------------------------------------ </option>';output+='<option value="us"> - Partners Websites - </option>';output+='<option value="us"> ------------------------------------ </option>';for(var j in planguages){output+='<option value="p_'+j+'">'+planguages[j]+'</option>';};output+='</select>';$('.langselect').append(output);var a=1;};function showCountriesWorking200(){var output='';output+='<select id="country_id" class="input_edit" style="display:inline" name="country_id" onChange="jumpCountryToURL(this,document);">';for(var i in languages){output+='<option value="'+i+'"';if(i==multilang_js['DEFAULT_LANGUAGE']){output+=' SELECTED ';try {$(".menu_country").attr("title",languages_countries[i]);$(".menu_country").html(languages_countries[i]);}catch(err){};};output+='>'+languages[i]+'</option>';};output+='<option value="us"> ------------------------------------ </option>';output+='<option value="us"> - Partners Websites - </option>';output+='<option value="us"> ------------------------------------ </option>';for(var j in planguages){output+='<option value="p_'+j+'">'+planguages[j]+'</option>';};output+='</select>';$('.langselect').append(output);var a=1;};if(typeof StoreProducts=='undefined'||StoreProducts===null){StoreProducts=new Object();};if(typeof StoreProducts.product=='undefined'||StoreProducts.product===null){StoreProducts.product=new Object();};if(typeof StoreProducts.events=='undefined'||StoreProducts.events===null){StoreProducts.events=new Object();};StoreProducts.initSelector=function(config){var product_id=null;var users_class=null;var selected_users=3;var selected_years=1;var years_class=null;var price_class=null;var full_price_class=null;var discounted_price_class=null;var buy_class=null;var onChangeUsers=null;var onChangeYears=null;var onSelectorLoad=null;var discount=null;var extra_params=null;var doAjax=true;var force_platform=null;var user_label='';var year_label='';var users_label='';var years_label='';var user_label_prefix='';var users_label_prefix='';var year_label_prefix='';var years_label_prefix='';var ignore_promotions=false;if('product_id'in config)product_id=config['product_id'];if('users_class'in config)users_class=config['users_class'];if('years_class'in config)years_class=config['years_class'];if('selected_users'in config)selected_users=config['selected_users'];if('selected_years'in config)selected_years=config['selected_years'];if('price_class'in config)price_class=config['price_class'];if('full_price_class'in config)full_price_class=config['full_price_class'];if('discounted_price_class'in config)discounted_price_class=config['discounted_price_class'];if('buy_class'in config)buy_class=config['buy_class'];if('user_label'in config)user_label=config['user_label'];if('users_label'in config)users_label=config['users_label'];if('year_label'in config)year_label=config['year_label'];if('years_label'in config)years_label=config['years_label'];if('user_label_prefix'in config)user_label_prefix=config['user_label_prefix'];if('users_label_prefix'in config)users_label_prefix=config['users_label_prefix'];if('year_label_prefix'in config)year_label_prefix=config['year_label_prefix'];if('years_label_prefix'in config)years_label_prefix=config['years_label_prefix'];if('extra_params'in config)extra_params=config['extra_params'];if('discount'in config)discount=config['discount'];if('doAjax'in config)doAjax=config['doAjax'];if('force_platform'in config)force_platform=config['force_platform'];if('onChangeUsers'in config)onChangeUsers=config['onChangeUsers'];if('onChangeYears'in config)onChangeYears=config['onChangeYears'];if('onSelectorLoad'in config)onSelectorLoad=config['onSelectorLoad'];if('ignore_promotions'in config)ignore_promotions=config['ignore_promotions'];if(product_id==null)return false;var urlParams={};try {(function(){var e,a=/\+/g,r=/([^&=]+)=?([^&]*)/g,d=function(s){return decodeURIComponent(s.replace(a," "));},q=window.location.search.substring(1);while(e=r.exec(q))urlParams[d(e[1])]=d(e[2]);})();if('force_country'in urlParams){if(extra_params==null){extra_params={'force_country':urlParams['force_country']};}else {extra_params['force_country']=urlParams['force_country'];};};if('cid'in urlParams){config['cid']=urlParams['cid'];};if('icid'in urlParams){config['icid']=urlParams['icid'];};}catch(ex){};if(typeof StoreProducts.product[product_id]=='undefined'||StoreProducts.product[product_id]===null){if(doAjax==true){var c_config=new Object();c_config['users_class']=users_class;c_config['years_class']=years_class;c_config['price_class']=price_class;c_config['full_price_class']=full_price_class;c_config['discounted_price_class']=discounted_price_class;c_config['buy_class']=buy_class;c_config['product_id']=product_id;c_config['extra_params']=extra_params;c_config['discount']=discount;c_config['user_label']=user_label;c_config['users_label']=users_label;c_config['year_label']=year_label;c_config['years_label']=years_label;c_config['user_label_prefix']=user_label_prefix;c_config['users_label_prefix']=users_label_prefix;c_config['year_label_prefix']=year_label_prefix;c_config['years_label_prefix']=years_label_prefix;c_config['ignore_promotions']=ignore_promotions;c_config['onChangeUsers']=onChangeUsers;c_config['onChangeYears']=onChangeYears;var on_users_change=null;var on_years_change=null;if(users_class!=null)on_users_change=StoreProducts.__onChangeUsers;if(years_class!=null)on_years_change=StoreProducts.__onChangeYears;if(users_class!=null){StoreProducts['events'][users_class]=new Object();StoreProducts['events'][users_class].onUsersChangeF=on_users_change;StoreProducts['events'][users_class].onUsersChangeD=c_config;};if(years_class!=null){StoreProducts['events'][years_class]=new Object();StoreProducts['events'][years_class].onYearsChangeF=on_years_change;StoreProducts['events'][years_class].onYearsChangeD=c_config;};if(years_class!=null&&users_class!=null){StoreProducts['events'][users_class+years_class]=new Object();StoreProducts['events'][users_class+years_class].onSelectorLoad=onSelectorLoad;};var so=new Object();so.ev=1;so.product_id=product_id;config['doAjax']=false;config['onSelectorLoad']=null;config['onChangeUsers']=null;config['onChangeYears']=null;so.config=config;var url='/site/Store/ajax';try {if(typeof multilang_js!='undefined'&&multilang_js!=null&&window.location.href.match(/www2.bitdefender.com/gi))if('DEFAULT_LANGUAGE'in multilang_js)url='/'+multilang_js['DEFAULT_LANGUAGE']+'/Store/ajax';if(typeof BASE_URI!='undefined'){if(BASE_URI!=null){if(BASE_URI.length>0)url=BASE_URI+'/Store/ajax';};};}catch(ex){};try {if('force_country'in urlParams){url=url+'?force_country='+urlParams['force_country'];};}catch(ex){};so=JSON.stringify(so);$.post(url,{data:so},function(data){var response_code=data['code'];var response_data=data['data'];if(response_code!=0){}else {try{var product_info=response_data['product']['product_id'];var product_id=response_data['product']['product_id'];var product_alias=response_data['product']['product_alias'];if(!(product_info in StoreProducts.product))product_info=product_alias;StoreProducts['product'][response_data['product']['product_id']]=response_data['product'];StoreProducts['product'][response_data['product']['product_alias']]=response_data['product'];StoreProducts.initSelector(response_data['config']);}catch(ex){};};},"json");return false;}else return false;}else {if(!(users_class+years_class in StoreProducts['events']))StoreProducts['events'][users_class+years_class]=new Object();if(!(users_class in StoreProducts['events']))StoreProducts['events'][users_class]=new Object();if(!(years_class in StoreProducts['events']))StoreProducts['events'][years_class]=new Object();if(typeof StoreProducts['events'][users_class+years_class].onSelectorLoad=='undefined'||StoreProducts['events'][users_class+years_class].onSelectorLoad===null)StoreProducts['events'][users_class+years_class].onSelectorLoad=onSelectorLoad;if(typeof StoreProducts['events'][users_class].onUsersChangeF=='undefined'||StoreProducts['events'][users_class].onUsersChangeF===null){c_config=new Object();c_config['users_class']=users_class;c_config['years_class']=years_class;c_config['price_class']=price_class;c_config['full_price_class']=full_price_class;c_config['discounted_price_class']=discounted_price_class;c_config['buy_class']=buy_class;c_config['product_id']=product_id;c_config['user_label']=user_label;c_config['users_label']=users_label;c_config['year_label']=year_label;c_config['years_label']=years_label;c_config['user_label_prefix']=user_label_prefix;c_config['users_label_prefix']=users_label_prefix;c_config['year_label_prefix']=year_label_prefix;c_config['years_label_prefix']=years_label_prefix;c_config['extra_params']=extra_params;c_config['discount']=discount;c_config['ignore_promotions']=ignore_promotions;c_config['onChangeUsers']=onChangeUsers;c_config['onChangeYears']=onChangeYears;var on_users_change=null;if(users_class!=null)on_users_change=StoreProducts.__onChangeUsers;if(users_class!=null){StoreProducts['events'][users_class].onUsersChangeF=on_users_change;StoreProducts['events'][users_class].onUsersChangeD=c_config;};};if(typeof StoreProducts['events'][years_class].onYearsChangeF=='undefined'||StoreProducts['events'][years_class].onYearsChangeF===null){c_config=new Object();c_config['users_class']=users_class;c_config['years_class']=years_class;c_config['price_class']=price_class;c_config['full_price_class']=full_price_class;c_config['discounted_price_class']=discounted_price_class;c_config['buy_class']=buy_class;c_config['product_id']=product_id;c_config['user_label']=user_label;c_config['users_label']=users_label;c_config['year_label']=year_label;c_config['years_label']=years_label;c_config['extra_params']=extra_params;c_config['discount']=discount;c_config['user_label_prefix']=user_label_prefix;c_config['users_label_prefix']=users_label_prefix;c_config['year_label_prefix']=year_label_prefix;c_config['years_label_prefix']=years_label_prefix;c_config['ignore_promotions']=ignore_promotions;c_config['onChangeUsers']=onChangeUsers;c_config['onChangeYears']=onChangeYears;var on_years_change=null;if(years_class!=null)on_years_change=StoreProducts.__onChangeYears;if(years_class!=null){StoreProducts['events'][years_class].onYearsChangeF=on_years_change;StoreProducts['events'][years_class].onYearsChangeD=c_config;};};if(users_class!=null)$("."+users_class).bind('change',StoreProducts['events'][users_class].onUsersChangeD,StoreProducts['events'][users_class].onUsersChangeF);if(years_class!=null)$("."+years_class).bind('change',StoreProducts['events'][years_class].onYearsChangeD,StoreProducts['events'][years_class].onYearsChangeF);};try {var l_hash=location.hash;if(l_hash.length<1){if('var'in urlParams)l_hash=urlParams['var'];};if(l_hash.length>1){var pt=new RegExp(StoreProducts.product[product_id]['product_alias']+"\\-(\\d{1,2})u\\-(\\d{1})y");if(pt!=null){r=pt.exec(l_hash);if($.isArray(r))if(r.length==3){if(r[1]in StoreProducts.product[product_id]['variations'])selected_users=r[1];if(r[2]in StoreProducts.product[product_id]['variations'][selected_users])selected_years=r[2];};};};}catch(ex){};var users=new Array();if(users_class!=null){try{for(i in StoreProducts.product[product_id]['variations'])users.push(i);users=users.sort(function(a,b){return a-b;});}catch(ex){};$.each(users,function(key,value){var label=users_label_prefix+' '+value+' '+users_label;if(value==1)label=user_label_prefix+' '+value+' '+user_label;label=$.trim(label);$("."+users_class).append($('<option>',{value:value}).text(label));});$("."+users_class+" [value=\""+selected_users+"\"]").attr('selected',true);if($("."+users_class).length)selected_users=$("."+users_class).val();};var years=new Array();if(years_class!=null){try {for(i in StoreProducts.product[product_id]['variations'][selected_users])years.push(i);years=years.sort(function(a,b){return a-b;});}catch(ex){};$.each(years,function(key,value){var label=years_label_prefix+' '+value+' '+years_label;if(value==1)label=year_label_prefix+' '+value+' '+year_label;label=$.trim(label);$("."+years_class).append($('<option>',{value:value}).text(label));});$("."+years_class+" [value=\""+selected_years+"\"]").attr('selected',true);if($("."+years_class).length)selected_years=$("."+years_class).val();};var variation=null;var base_uri='';try {variation=StoreProducts.product[product_id]['variations'][selected_users][selected_years];base_uri=StoreProducts.product[product_id]['base_uri'];}catch(ex){};if(variation==null){try {min_users=0;for(i in StoreProducts.product[product_id]['variations']){if(min_users<i)min_users=i;};if(min_users>0){selected_users=min_users;min_years=0;for(i in StoreProducts.product[product_id]['variations'][selected_users]){if(min_years<i)min_years=i;};if(min_years>0){selected_years=min_years;variation=StoreProducts.product[product_id]['variations'][selected_users][selected_years];base_uri=StoreProducts.product[product_id]['base_uri'];};};}catch(ex){};};if(variation==null)return false;var price=variation['price']+' '+variation['currency_label'];price=StoreProducts.formatPrice(variation['price'],variation['currency_label'],variation['region_id']);var discounted_price='';var full_price=price;var buy_link=base_uri+'/Store/buy/'+product_id+'/'+selected_users+'/'+selected_years;try {if('discount'in variation){if('discounted_price'in variation['discount']){discounted_price=StoreProducts.formatPrice(variation['discount']['discounted_price'],variation['currency_label'],variation['region_id']);price='<span class="store_price_full">'+price+'</span><span class="store_price_cut">'+discounted_price+'</span>';};if('coupon'in variation['discount']){variation['discount']['coupon']=$.trim(variation['discount']['coupon']);if(variation['discount']['coupon'].length>0)buy_link=base_uri+'/Store/buy/'+product_id+'/'+selected_users+'/'+selected_years+'/'+'coupon.'+encodeURIComponent(variation['discount']['coupon'])+'/'+'platform.'+variation['platform_id'];else buy_link=base_uri+'/Store/buy/'+product_id+'/'+selected_users+'/'+selected_years+'/'+'platform.'+variation['platform_id'];};if('ref'in variation['discount']){if(variation['discount']['ref'].length>0)buy_link=buy_link+'/ref.'+variation['discount']['ref'];};}else {if(discount!=null){discounted_price=StoreProducts.getDiscountedPrice(variation['price'],discount);discounted_price=StoreProducts.formatPrice(discounted_price,variation['currency_label'],variation['region_id']);price='<span class="store_price_full">'+price+'</span><span class="store_price_cut">'+discounted_price+'</span>';};};}catch(ex){};try {if(extra_params!=null){var params='';for(op in extra_params){if(op=='force_country')continue;extra_params[op]=$.trim(extra_params[op]);if(extra_params[op].length<1)continue;var re=new RegExp(op+'.[^/]*/?','g');buy_link=buy_link.replace(re,'');buy_link=buy_link.replace(/\/$/g,'');if(params.length==0)params='/'+op+'.'+encodeURIComponent(extra_params[op]);else params=params+'/'+op+'.'+encodeURIComponent(extra_params[op]);};if(params.length>1)buy_link=buy_link+params;if('force_country'in extra_params)buy_link=buy_link+'?force_country='+extra_params['force_country'];};}catch(ex){};if(price_class!=null)$("."+price_class).html(price);try {if(price_class!=null){var p_len=full_price.length+discounted_price.length;if(p_len<=10)$("."+price_class).addClass("price_small");if(p_len>10&&p_len<=18)$("."+price_class).addClass("price_medium");if(p_len>18)$("."+price_class).addClass("price_large");};}catch(ex){};full_price='<span class="store_price_full">'+full_price+'</span>';discounted_price='<span class="store_price_cut">'+discounted_price+'</span>';if(discounted_price_class!=null)$("."+discounted_price_class).html(discounted_price);if(full_price_class!=null)$("."+full_price_class).html(full_price);if(buy_class!=null)$("."+buy_class).attr('href',buy_link);try {ocg=StoreProducts['events'][users_class+years_class].onSelectorLoad;var thisObj=new Object();thisObj['selected_users']=selected_users;thisObj['selected_years']=selected_years;thisObj['selected_variation']=variation;thisObj['buy_link']=buy_link;thisObj['config']=config;if(ocg!=null){ocg.call(thisObj);};if('promotion_functions'in variation){if(variation['promotion_functions'].length>0){var jsc=Base64.decode(variation['promotion_functions']);var PromotionFunctions=null;eval(jsc);StoreProducts['events'][users_class+years_class].promotionsCleanUp={};if('cleanUp'in PromotionFunctions){StoreProducts['events'][users_class+years_class].promotionsCleanUp[variation['promotion']]=PromotionFunctions.cleanUp;};ocg=PromotionFunctions.onLoad;ocg.call(thisObj);};};}catch(ex){};};StoreProducts.truncatePrice=function(price){var ret=price;try{if(ret>=0)ret=Math.floor(ret);else ret=Math.ceil(ret);if(price!=ret)ret=price;}catch(ex){};return ret;};StoreProducts.formatPrice=function(price,currency,region){price=StoreProducts.truncatePrice(price);if(region==3)return currency+price;if(region==4)return currency+' '+price;if(region==5)return price+' '+currency;if(region==7)return price+' '+currency;if(region==8||region==2)return currency+price;if(region==13)return currency+' '+price;return price+' '+currency;};StoreProducts.getDiscountedPrice=function(val,pc){var dp=(val*pc)/100;val=val-dp;val=val.toFixed(2);return val;};StoreProducts.__onChangeUsers=function(ev){var c_config=ev.data;var selected_users=$("."+c_config['users_class']).val();var years=new Array();try {for(i in StoreProducts.product[c_config['product_id']]['variations'][selected_users])years.push(i);years=years.sort(function(a,b){return a-b;});}catch(ex){};$("."+c_config['years_class']).empty();$.each(years,function(key,value){var label=value+' '+c_config['years_label'];if(value==1)label=value+' '+c_config['year_label'];$("."+c_config['years_class']).append($('<option>',{value:value}).text(label));});var selected_years=$("."+c_config['years_class']).val();var variation=null;var base_uri='';try {variation=StoreProducts.product[c_config['product_id']]['variations'][selected_users][selected_years];base_uri=StoreProducts.product[c_config['product_id']]['base_uri'];}catch(ex){};if(variation==null)return null;var price=variation['price']+' '+variation['currency_label'];price=StoreProducts.formatPrice(variation['price'],variation['currency_label'],variation['region_id']);var discounted_price='';var full_price=price;var buy_link=base_uri+'/Store/buy/'+c_config['product_id']+'/'+selected_users+'/'+selected_years;try {if('discount'in variation){if('discounted_price'in variation['discount']){discounted_price=StoreProducts.formatPrice(variation['discount']['discounted_price'],variation['currency_label'],variation['region_id']);price='<span class="store_price_full">'+price+'</span><span class="store_price_cut">'+discounted_price+'</span>';};if('coupon'in variation['discount']){variation['discount']['coupon']=$.trim(variation['discount']['coupon']);if(variation['discount']['coupon'].length>0)buy_link=base_uri+'/Store/buy/'+c_config['product_id']+'/'+selected_users+'/'+selected_years+'/'+'coupon.'+encodeURIComponent(variation['discount']['coupon'])+'/'+'platform.'+variation['platform_id'];else buy_link=base_uri+'/Store/buy/'+c_config['product_id']+'/'+selected_users+'/'+selected_years+'/'+'platform.'+variation['platform_id'];};if('ref'in variation['discount']){if(variation['discount']['ref'].length>0)buy_link=buy_link+'/ref.'+variation['discount']['ref'];};}else {if(discount in c_config){if(c_config['discount']!=null){discounted_price=StoreProducts.getDiscountedPrice(variation['price'],discount);discounted_price=StoreProducts.formatPrice(discounted_price,variation['currency_label'],variation['region_id']);price='<span class="store_price_full">'+price+'</span><span class="store_price_cut">'+discounted_price+'</span>';};};};}catch(ex){};try {if('extra_params'in c_config){if(c_config['extra_params']!=null){var params='';for(op in c_config['extra_params']){if(op=='force_country')continue;c_config['extra_params'][op]=$.trim(c_config['extra_params'][op]);if(c_config['extra_params'][op].length<1)continue;var re=new RegExp(op+'.[^/]*/?','g');buy_link=buy_link.replace(re,'');buy_link=buy_link.replace(/\/$/g,'');if(params.length==0)params='/'+op+'.'+encodeURIComponent(c_config['extra_params'][op]);else params=params+'/'+op+'.'+encodeURIComponent(c_config['extra_params'][op]);};if(params.length>1)buy_link=buy_link+params;if('force_country'in c_config['extra_params'])buy_link=buy_link+'?force_country='+c_config['extra_params']['force_country'];};};}catch(ex){};$("."+c_config['price_class']).html(price);full_price='<span class="store_price_full">'+full_price+'</span>';discounted_price='<span class="store_price_cut">'+discounted_price+'</span>';if(c_config['discounted_price_class']!=null)$("."+c_config['discounted_price_class']).html(discounted_price);if(c_config['full_price_class']!=null)$("."+c_config['full_price_class']).html(full_price);$("."+c_config['buy_class']).attr('href',buy_link);try {var ocg=c_config['onChangeUsers'];var thisObj=new Object();thisObj['selected_users']=selected_users;thisObj['selected_years']=selected_years;thisObj['selected_variation']=variation;thisObj['buy_link']=buy_link;thisObj['config']=c_config;if(ocg!=null){ocg.call(thisObj);};var users_class=c_config['users_class'];var years_class=c_config['years_class'];if('promotionsCleanUp'in StoreProducts['events'][users_class+years_class]){for(iev in StoreProducts['events'][users_class+years_class].promotionsCleanUp){ocg=StoreProducts['events'][users_class+years_class].promotionsCleanUp[iev];ocg.call(thisObj);};};if('promotion_functions'in variation){if(variation['promotion_functions'].length>0){var jsc=Base64.decode(variation['promotion_functions']);var PromotionFunctions=null;eval(jsc);if(!('promotionsCleanUp'in StoreProducts['events'][users_class+years_class]))StoreProducts['events'][users_class+years_class].promotionsCleanUp={};if('cleanUp'in PromotionFunctions){if(!(variation['promotion']in StoreProducts['events'][users_class+years_class].promotionsCleanUp))StoreProducts['events'][users_class+years_class].promotionsCleanUp[variation['promotion']]=PromotionFunctions.cleanUp;};ocg=PromotionFunctions.onChange;ocg.call(thisObj);};};}catch(ex){};};StoreProducts.__onChangeYears=function(ev){var c_config=ev.data;var selected_users=$("."+c_config['users_class']).val();var selected_years=$("."+c_config['years_class']).val();var variation=null;var base_uri='';try {variation=StoreProducts.product[c_config['product_id']]['variations'][selected_users][selected_years];base_uri=StoreProducts.product[c_config['product_id']]['base_uri'];}catch(ex){};if(variation==null)return false;var price=variation['price']+' '+variation['currency_label'];price=StoreProducts.formatPrice(variation['price'],variation['currency_label'],variation['region_id']);var discounted_price='';var full_price=price;var buy_link=base_uri+'/Store/buy/'+c_config['product_id']+'/'+selected_users+'/'+selected_years;try {if('discount'in variation){if('discounted_price'in variation['discount']){discounted_price=StoreProducts.formatPrice(variation['discount']['discounted_price'],variation['currency_label'],variation['region_id']);price='<span class="store_price_full">'+price+'</span><span class="store_price_cut">'+discounted_price+'</span>';};if('coupon'in variation['discount']){variation['discount']['coupon']=$.trim(variation['discount']['coupon']);if(variation['discount']['coupon'].length>0)buy_link=base_uri+'/Store/buy/'+c_config['product_id']+'/'+selected_users+'/'+selected_years+'/'+'coupon.'+encodeURIComponent(variation['discount']['coupon'])+'/'+'platform.'+variation['platform_id'];else buy_link=base_uri+'/Store/buy/'+c_config['product_id']+'/'+selected_users+'/'+selected_years+'/'+'platform.'+variation['platform_id'];};if('ref'in variation['discount']){if(variation['discount']['ref'].length>0)buy_link=buy_link+'/ref.'+variation['discount']['ref'];};}else {if(discount in c_config){if(c_config['discount']!=null){discounted_price=StoreProducts.getDiscountedPrice(variation['price'],discount);discounted_price=StoreProducts.formatPrice(discounted_price,variation['currency_label'],variation['region_id']);price='<span class="store_price_full">'+price+'</span><span class="store_price_cut">'+discounted_price+'</span>';};};};}catch(ex){};try {if('extra_params'in c_config){if(c_config['extra_params']!=null){var params='';for(op in c_config['extra_params']){if(op=='force_country')continue;c_config['extra_params'][op]=$.trim(c_config['extra_params'][op]);if(c_config['extra_params'][op].length<1)continue;var re=new RegExp(op+'.[^/]*/?','g');buy_link=buy_link.replace(re,'');buy_link=buy_link.replace(/\/$/g,'');if(params.length==0)params='/'+op+'.'+encodeURIComponent(c_config['extra_params'][op]);else params=params+'/'+op+'.'+encodeURIComponent(c_config['extra_params'][op]);};if(params.length>1)buy_link=buy_link+params;if('force_country'in c_config['extra_params'])buy_link=buy_link+'?force_country='+c_config['extra_params']['force_country'];};};}catch(ex){};$("."+c_config['price_class']).html(price);full_price='<span class="store_price_full">'+full_price+'</span>';discounted_price='<span class="store_price_cut">'+discounted_price+'</span>';if(c_config['discounted_price_class']!=null)$("."+c_config['discounted_price_class']).html(discounted_price);if(c_config['full_price_class']!=null)$("."+c_config['full_price_class']).html(full_price);$("."+c_config['buy_class']).attr('href',buy_link);try {var ocg=c_config['onChangeYears'];var thisObj=new Object();thisObj['selected_users']=selected_users;thisObj['selected_years']=selected_years;thisObj['selected_variation']=variation;thisObj['buy_link']=buy_link;thisObj['config']=c_config;if(ocg!=null){ocg.call(thisObj);};var users_class=c_config['users_class'];var years_class=c_config['years_class'];if('promotionsCleanUp'in StoreProducts['events'][users_class+years_class]){for(iev in StoreProducts['events'][users_class+years_class].promotionsCleanUp){ocg=StoreProducts['events'][users_class+years_class].promotionsCleanUp[iev];ocg.call(thisObj);};};if('promotion_functions'in variation){if(variation['promotion_functions'].length>0){var jsc=Base64.decode(variation['promotion_functions']);var PromotionFunctions=null;eval(jsc);if(!('promotionsCleanUp'in StoreProducts['events'][users_class+years_class]))StoreProducts['events'][users_class+years_class].promotionsCleanUp={};if('cleanUp'in PromotionFunctions){if(!(variation['promotion']in StoreProducts['events'][users_class+years_class].promotionsCleanUp))StoreProducts['events'][users_class+years_class].promotionsCleanUp[variation['promotion']]=PromotionFunctions.cleanUp;};ocg=PromotionFunctions.onChange;ocg.call(thisObj);};};}catch(ex){};};Base64={"_keyStr":"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=","encode":function(input){var output="";var chr1,chr2,chr3,enc1,enc2,enc3,enc4;var i=0;input=Base64._utf8_encode(input);while(i<input.length){chr1=input.charCodeAt(i++);chr2=input.charCodeAt(i++);chr3=input.charCodeAt(i++);enc1=chr1>>2;enc2=((chr1&3)<<4)|(chr2>>4);enc3=((chr2&15)<<2)|(chr3>>6);enc4=chr3&63;if(isNaN(chr2)){enc3=enc4=64;}else if(isNaN(chr3)){enc4=64;};output=output+this._keyStr.charAt(enc1)+this._keyStr.charAt(enc2)+this._keyStr.charAt(enc3)+this._keyStr.charAt(enc4);};return output;},"decode":function(input){var output="";var chr1,chr2,chr3;var enc1,enc2,enc3,enc4;var i=0;input=input.replace(/[^A-Za-z0-9\+\/\=]/g,"");while(i<input.length){enc1=this._keyStr.indexOf(input.charAt(i++));enc2=this._keyStr.indexOf(input.charAt(i++));enc3=this._keyStr.indexOf(input.charAt(i++));enc4=this._keyStr.indexOf(input.charAt(i++));chr1=(enc1<<2)|(enc2>>4);chr2=((enc2&15)<<4)|(enc3>>2);chr3=((enc3&3)<<6)|enc4;output=output+String.fromCharCode(chr1);if(enc3!=64){output=output+String.fromCharCode(chr2);};if(enc4!=64){output=output+String.fromCharCode(chr3);};};output=Base64._utf8_decode(output);return output;},"_utf8_encode":function(string){string=string.replace(/\r\n/g,"\n");var utftext="";for(var n=0;n<string.length;n++){var c=string.charCodeAt(n);if(c<128){utftext+=String.fromCharCode(c);}else if((c>127)&&(c<2048)){utftext+=String.fromCharCode((c>>6)|192);utftext+=String.fromCharCode((c&63)|128);}else{utftext+=String.fromCharCode((c>>12)|224);utftext+=String.fromCharCode(((c>>6)&63)|128);utftext+=String.fromCharCode((c&63)|128);};};return utftext;},"_utf8_decode":function(utftext){var string="";var i=0;var c=0;var c1=0;var c2=0;while(i<utftext.length){c=utftext.charCodeAt(i);if(c<128){string+=String.fromCharCode(c);i++;}else if((c>191)&&(c<224)){c2=utftext.charCodeAt(i+1);string+=String.fromCharCode(((c&31)<<6)|(c2&63));i+=2;}else{c2=utftext.charCodeAt(i+1);c3=utftext.charCodeAt(i+2);string+=String.fromCharCode(((c&15)<<12)|((c2&63)<<6)|(c3&63));i+=3;};};return string;}};var JSON;if(!JSON){JSON={};}(function(){function str(a,b){var c,d,e,f,g=gap,h,i=b[a];if(i&&typeof i==="object"&&typeof i.toJSON==="function"){i=i.toJSON(a)}if(typeof rep==="function"){i=rep.call(b,a,i)}switch(typeof i){case"string":return quote(i);case"number":return isFinite(i)?String(i):"null";case"boolean":case"null":return String(i);case"object":if(!i){return"null"}gap+=indent;h=[];if(Object.prototype.toString.apply(i)==="[object Array]"){f=i.length;for(c=0;c<f;c+=1){h[c]=str(c,i)||"null"}e=h.length===0?"[]":gap?"[\n"+gap+h.join(",\n"+gap)+"\n"+g+"]":"["+h.join(",")+"]";gap=g;return e}if(rep&&typeof rep==="object"){f=rep.length;for(c=0;c<f;c+=1){if(typeof rep[c]==="string"){d=rep[c];e=str(d,i);if(e){h.push(quote(d)+(gap?": ":":")+e)}}}}else{for(d in i){if(Object.prototype.hasOwnProperty.call(i,d)){e=str(d,i);if(e){h.push(quote(d)+(gap?": ":":")+e)}}}}e=h.length===0?"{}":gap?"{\n"+gap+h.join(",\n"+gap)+"\n"+g+"}":"{"+h.join(",")+"}";gap=g;return e}}function quote(a){escapable.lastIndex=0;return escapable.test(a)?'"'+a.replace(escapable,function(a){var b=meta[a];return typeof b==="string"?b:"\\u"+("0000"+a.charCodeAt(0).toString(16)).slice(-4)})+'"':'"'+a+'"'}function f(a){return a<10?"0"+a:a}"use strict";if(typeof Date.prototype.toJSON!=="function"){Date.prototype.toJSON=function(a){return isFinite(this.valueOf())?this.getUTCFullYear()+"-"+f(this.getUTCMonth()+1)+"-"+f(this.getUTCDate())+"T"+f(this.getUTCHours())+":"+f(this.getUTCMinutes())+":"+f(this.getUTCSeconds())+"Z":null};String.prototype.toJSON=Number.prototype.toJSON=Boolean.prototype.toJSON=function(a){return this.valueOf()}}var cx=/[\u0000\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,escapable=/[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,gap,indent,meta={"\b":"\\b","\t":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"},rep;if(typeof JSON.stringify!=="function"){JSON.stringify=function(a,b,c){var d;gap="";indent="";if(typeof c==="number"){for(d=0;d<c;d+=1){indent+=" "}}else if(typeof c==="string"){indent=c}rep=b;if(b&&typeof b!=="function"&&(typeof b!=="object"||typeof b.length!=="number")){throw new Error("JSON.stringify")}return str("",{"":a})}}if(typeof JSON.parse!=="function"){JSON.parse=function(text,reviver){function walk(a,b){var c,d,e=a[b];if(e&&typeof e==="object"){for(c in e){if(Object.prototype.hasOwnProperty.call(e,c)){d=walk(e,c);if(d!==undefined){e[c]=d}else{delete e[c]}}}}return reviver.call(a,b,e)}var j;text=String(text);cx.lastIndex=0;if(cx.test(text)){text=text.replace(cx,function(a){return"\\u"+("0000"+a.charCodeAt(0).toString(16)).slice(-4)})}if(/^[\],:{}\s]*$/.test(text.replace(/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,"@").replace(/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,"]").replace(/(?:^|:|,)(?:\s*\[)+/g,""))){j=eval("("+text+")");return typeof reviver==="function"?walk({"":j},""):j}throw new SyntaxError("JSON.parse")}}})();function Main(){};Main.CheckSubscribeForm=function(form){var email=form.elements["nfo[subscribe_email]"].value;if(!General.isEmail(email)){alert("Email address is not a valid format.");return false;};return true;};Main.CheckSendFeedbackForm=function(form){var author=form.elements["nfo[feedback_author]"].value;var email=form.elements["nfo[feedback_email]"].value;var content=form.elements["nfo[feedback_content]"].value;if(!General.isEmail(email)){alert("Email address is not a valid format.");return false;};if(author.length<3){alert("Please write your name.");return false;};if(content.length<5){alert("Feedback is to short.");return false;};return true;};function CheckSendContactForm(){var fname=document.getElementById("contact_firstname").value;var lname=document.getElementById("contact_lastname").value;var email=document.getElementById("email").value;var content=document.getElementById("content").value;var choose=document.getElementById("contact_department").value;var ret=true;var message='';if(multilang_js['DEFAULT_LANGUAGE']=='de'){if(choose=="Bitte auswahlen"){message="Bitte wählen Sie den Empfänger\n";ret=false;};};if(!General.isEmail(email)){message=message+multilang_js['_newsletter_general_valid_email_js']+"\n";ret=false;};if(fname.length==0){message=message+multilang_js['_newsletter_general_valid_firstname_js']+"\n";ret=false;};if(lname.length==0){message=message+multilang_js['_newsletter_general_valid_lastname_js']+"\n";ret=false;};if(content.length<5){message=message+multilang_js['_main_general_feedback_too_short_js']+"\n";ret=false;};var product=document.getElementById("product");var department=document.getElementById("contact_department");if(product){if((product.options[product.selectedIndex].value=='No product selected')&&(department.options[department.selectedIndex].value==3)){message=message+'Bitte wählen Sie ein Produkt aus'+"\n";product.focus();ret=false;};};if(ret==false){document.getElementById('submitBtn').disabled=false;alert(message);sub=0;return false;};return true;};function CheckSendNousContacterForm(myform){var logiciel=myform.elements["nfo[logiciel]"];var winVers=myform.elements["nfo[winVers]"];var email=myform.elements["nfo[email]"];var probleme=myform.elements["nfo[probleme]"];if(!General.isEmail(email.value)){alert("Le format de l'adresse e-mail est incorrect.");email.focus();return false;};if(logiciel.options[logiciel.selectedIndex].value==""){alert("Selectionner \"Logiciel\".");return false;};if(winVers.options[winVers.selectedIndex].value==""){alert("Selectionner \"Version de Windows\".");return false;};if(probleme.value=="Sélectionnez votre type de problème"){alert("Selectionner votre type de problème");return false;};return true;};Main.PushNewsForm=function(form){var ids=form.elements["nfo[push_news_text]"].value;if(!ids.match(/[\-0-9]$/)){alert("Only numbers[0-9] and - please");return false;};return true;};Main.AddZoneForm=function(form){return true;};Main.AddMailForm=function(form){var code=form.elements["nfo[mail_code]"].value;var module=form.elements["nfo[mail_module_id]"].value;var subject=form.elements["nfo[mail_subject]"].value;var from=form.elements["nfo[mail_from]"].value;var to=form.elements["nfo[mail_to]"].value;var reply=form.elements["nfo[mail_reply]"].value;var content=form.elements["content"].value;if(code.length<3){alert("Please write a code (at least 3 chars).");return false;};if(module==0||module==""){alert("Choose a module.");return false;};if(from!=""&&!from.match(/^[a-zA-Z\._\-0-9]{3,}@[a-z0-9\-_\.]{1,}\.[a-z]{2,}$/)){alert("From address is not a valid format.");return false;};if(to!=""&&!to.match(/^[a-zA-Z\._\-0-9]{3,}@[a-z0-9\-_\.]{1,}\.[a-z]{2,}$/)){alert("To address is not a valid format.");return false;};if(reply!=""&&!reply.match(/^[a-zA-Z\._\-0-9]{3,}@[a-z0-9\-_\.]{1,}\.[a-z]{2,}$/)){alert("Reply address is not a valid format.");return false;};if(from==""&&to==""){alert("FROM or TO must be provided.");return false;};if(subject.length<5){alert("Please write a subject (at least 5 chars).");return false;};if(content.length<10){alert("Body is to short.");return false;};return true;};Main.showFromAndToFields=function(form,combo,document){var string=combo.value;var from=document.getElementById('from');var to=document.getElementById('to');var reply=document.getElementById('reply');if(string==1){from.style.display='block';reply.style.display='block';to.style.display='none';}else if(string==2){to.style.display='block';from.style.display='none';reply.style.display='none';}else {from.style.display='none';to.style.display='none';reply.style.display='none';};return true;};Main.ViewPreview=function(document){var content=document.getElementById('content').value;var today=new Date();var zero_date=new Date(0,0,0);today.setTime(today.getTime()-zero_date.getTime());var cookie_expire_date=new Date(today.getTime()+(8*7*86400000));General.SetCookie("content",content,cookie_expire_date,"/",".bitdefender.com");window.open('/popup/preview.php','popuppage','width=500,height=400,top=100,left=100');return false;};function EnableStatesContactForm(value){if(value=='us'){document.getElementById('state_row').style.visibility='visible';}else{document.getElementById('state_row').style.visibility='hidden';};};function EnableProducts(value){if(value==1){document.getElementById('product_row').style.display='block';document.getElementById('product_row').style.visibility='visible';}else {document.getElementById('product_row').style.display='none';document.getElementById('product_row').style.visibility='hidden';};};function mouseOver(){document.beta.src="http://download.bitdefender.com/resources/files/Main/img/beta_mic_over.gif";};function mouseOut(){document.beta.src="http://download.bitdefender.com/resources/files/Main/img/beta_mic.gif";};function CheckSendContactFormRO(){var fname=document.getElementById("fname").value;var lname=document.getElementById("lname").value;var email=document.getElementById("email").value;var content=document.getElementById("comments").value;var choose=document.getElementById("contact_department").value;var ret=true;var message='';if(multilang_js['DEFAULT_LANGUAGE']=='de'){if(choose=="Bitte auswahlen"){message="Bitte wäahlen Sie Ihr auswählen \n";ret=false;};};if(!General.isEmail(email)){message=message+multilang_js['_newsletter_general_valid_email_js']+"\n";ret=false;};if(fname.length==0){message=message+multilang_js['_newsletter_general_valid_firstname_js']+"\n";ret=false;};if(lname.length==0){message=message+multilang_js['_newsletter_general_valid_lastname_js']+"\n";ret=false;};if(content.length<5){message=message+multilang_js['_main_general_feedback_too_short_js']+"\n";ret=false;};var product=document.getElementById("product");var department=document.getElementById("contact_department");if(product){if((product.options[product.selectedIndex].value=='No product selected')&&(department.options[department.selectedIndex].value==3)){message=message+'Bitte wählen Sie ein Produkt aus'+"\n";product.focus();ret=false;};};if(ret==false){alert(message);sub=0;return false;};return true;};
