var SecondsLeft=0;var startDays=10;var startHours=12;var startMinutes=15;var startSeconds=2;function af(days,hours,minutes,seconds){SecondsLeft=days*86400+hours*3600+minutes*60+seconds;ar(timer);};function ag(){var tempSeconds=SecondsLeft;var days=parseInt(tempSeconds/86400,10);tempSeconds=tempSeconds%86400;var hours=parseInt(tempSeconds/3600,10);tempSeconds=tempSeconds%3600;var minutes=parseInt(tempSeconds/60,10);tempSeconds=tempSeconds%60;var output="";if(days>0){if(days==1){output+=days+" day ";}else{output+=days+" days ";}}output+=(hours<10?"0":"")+hours+":";output+=(minutes<10?"0":"")+minutes+":";output+=(tempSeconds<10?"0":"")+tempSeconds;return output};function ar(){document.getElementById('Timer').innerHTML=ag();if(SecondsLeft<=0)return;SecondsLeft--;setTimeout('ar()',1000);};function aA(arrRegions,arrLotteries){var country_sel=document.getElementById('country').options[document.getElementById('country').selectedIndex].value;if(country_sel!='#'){document.getElementById('lottery').length=0;document.getElementById('lottery').options[0]=new Option('','#','defaultSelected');var i=1;for(var lot in arrLotteries){if(country_sel==arrRegions[arrLotteries[lot]['reg_id']]['country_id']){document.getElementById('lottery').options[i]=new Option(arrRegions[arrLotteries[lot]['reg_id']]['reg_name']+' - '+arrLotteries[lot]['lot_name'],lot,'');i++;}}}else{document.getElementById('lottery').length=0;document.getElementById('lottery').options[0]=new Option('','#','defaultSelected');i=1;for(var lot in arrLotteries){document.getElementById('lottery').options[i]=new Option(arrRegions[arrLotteries[lot]['reg_id']]['reg_name']+' - '+arrLotteries[lot]['lot_name'],lot,'');i++;}}};var timer=null;function bz(){bp(0);};function bp(offset){var dateTime=new Date(dtNow.getTime()+parseInt(offset));var hours=dateTime.getHours();var minutes=dateTime.getMinutes();minutes=((minutes<10)?"0":"")+minutes;var seconds=dateTime.getSeconds();seconds=((seconds<10)?"0":"")+seconds;var clock=hours+":"+minutes+":"+seconds;document.getElementById('idTimeBlue').innerHTML=clock;document.getElementById('idTimeBlue').display;offset=parseInt(offset)+1000;setTimeout("bp("+offset+")",1000);var months=new Array('Julio');var date="";month=months[0];date=dateTime.getDate()+" "+month+" "+dateTime.getFullYear();document.getElementById("Time").innerHTML=date;};var countDownCounter;function bx(pCaptionDay,pCaptionDays,countDownCounter1){sCaptionDay=pCaptionDay;sCaptionDays=pCaptionDays;countDownCounter=countDownCounter1;bn(0);};function bn(offset){for(var index=1;index<=countDownCounter;index++){setTime(index,offset,parseInt(eval('time_Y'+index)),parseInt(eval('time_M'+index)),parseInt(eval('time_D'+index)),parseInt(eval('time_HH'+index)),parseInt(eval('time_MM'+index)));}offset=parseInt(offset)+1000;setTimeout("bn("+offset+")",1000);};function setTime(index,offset,closeYear,closeMonth,closeDay,closeHour,closeMinute,closeSecond){var dtClose=new Date(closeYear,parseInt(closeMonth)-1,closeDay,closeHour,closeMinute);var milliseconds1=dtClose.getTime();var milliseconds2=dtNow.getTime();var difference=milliseconds1-(milliseconds2+offset);var prevDifference=milliseconds1-(milliseconds2+offset-1000);var d=Math.floor(difference/(1000*60*60*24));var h=Math.floor(difference/(1000*60*60))-d*24;var m=Math.floor(difference/(1000*60))-d*24*60-h*60;var s=Math.floor(difference/(1000))-d*24*60*60-h*60*60-m*60;var prevD=Math.floor(prevDifference/(1000*60*60*24));var prevH=Math.floor(prevDifference/(1000*60*60))-d*24;var daysImage;var isNextChangeImage=false;if(d<1){daysImage="";if(h>=0&&h<1){daysImage="<img src=images/test.congalotto.com/timer04.gif width='45' height='16' >";}if(h>=1&&h<6){daysImage="<img src=images/test.congalotto.com/timer03.gif width='45' height='16' >";}if(h>=6&&h<12){daysImage="<img src=images/test.congalotto.com/timer02.gif  height='16' >";}if(h>=12&&h<24){daysImage="<img src=images/test.congalotto.com/timer01.gif width='45' height='16' >";}}else{if(d==1)daysImage=d+" "+sCaptionDay;else daysImage=d+" "+sCaptionDays;}if(h<10)h="0"+h.toString();if(m<10)m="0"+m.toString();if(s<10)s="0"+s.toString();if(prevH!=h||prevD!=d||offset<=0){bw('td_lotto_countdown_days_'+index,daysImage);}var timeStr=h+":"+m+":"+s+"";bw('td_lotto_countdown_time_'+index,timeStr);};function bw(id,value){var obj;obj=document.getElementById(id);if(obj!=null){obj.innerHTML=value;}};function by(){if(arrOurWinners==null||arrOurWinners.length==0){return;}var tdOurWinnersContent=document.getElementById('tdOurWinnersContent');if(!tdOurWinnersContent)return;if(S()){tdOurWinnersContent.innerHTML=arrOurWinners[step];}else{tdOurWinnersContent.filters.blendTrans.apply();tdOurWinnersContent.innerHTML=arrOurWinners[step];tdOurWinnersContent.filters.blendTrans.play();}if(step<arrOurWinners.length-1)step++;else step=0;setTimeout("by()",4000);};function aC(num,displayWhichAlert){var tbl=null;var result=null;var checkBet=false;if("myUCPlayRequest_tblNumbers"==null)return false;if(num==1){tbl="myUCPlayRequest_tblNumbers";}else{tbl="myUCPlayRequest_tblNumbersAfterFive";}var tbl22=document.getElementById(tbl);if(tbl22!=null&&tbl22.rows.length>0){for(var i=0;i<tbl22.rows.length;i++){for(var j=0;j<tbl22.rows[i].cells.length;j++){if(tbl22.rows[i].cells[j].getAttribute("guess")=='true'||tbl22.rows[i].cells[j].getAttribute("guess")=='false'){if(tbl22.rows[i].cells[j].innerHTML==""){checkBet=false;N(displayWhichAlert);}else{checkBet=true;if(tbl22.rows[i].cells[j].getAttribute("guess")=='true'){aZ(tbl22.rows[i].cells[j].innerHTML);}if(tbl22.rows[i].cells[j].getAttribute("guess")=='false')aY(tbl22.rows[i].cells[j].innerHTML);}if(checkBet==false){return false;}}}}}else{return true;}};function aF(){var txtHiddenGuess=document.getElementById("txtHiddenGuess");if(txtHiddenGuess!=null)txtHiddenGuess.value="";var txtHiddenAdditional=document.getElementById("txtHiddenAdditional");if(txtHiddenAdditional!=null)txtHiddenAdditional.value="";var lblErrorPlay=document.getElementById("lblErrorPlay");if(lblErrorPlay!=null)lblErrorPlay.innerHTML="";};function aZ(x){var txtHiddenGuess=document.getElementById('txtHiddenGuess');if(txtHiddenGuess!=null){var text=x+";";txtHiddenGuess.value+=text;}};function aY(x){var txtHiddenAdditional=document.getElementById("txtHiddenAdditional");var text=x+";";txtHiddenAdditional.value+=text;};
function bk(){
	var txtHiddenIsActiveBlock=document.getElementById('txtHiddenIsActiveBlock');
	if(txtHiddenIsActiveBlock){
		txtHiddenIsActiveBlock.value='true';
	}
	var txtHiddenFirstNumber=document.getElementById('txtHiddenFirstNumber');
	var txtHiddenNumber=document.getElementById('txtHiddenNumber');
	if(txtHiddenNumber&&txtHiddenFirstNumber){
		txtHiddenNumber.value=txtHiddenFirstNumber.value;
	}
};function J(cell,hide){if(cell){if(S())cell.style.display=(hide?"none":"table-cell");else cell.style.display=(hide?"none":"");}};function K(div,hide){if(div){if(S()){div.style.display=(hide?"none":"block");}else div.style.display=(hide?"none":"");}};function L(row,hide){if(row){if(S()){row.style.display=(hide?"none":"table-row");}else row.style.display=(hide?"none":"");}};function M(table,hide){if(table){if(S()){table.style.display=(hide?"none":"table");}else table.style.display=(hide?"none":"");}};function S(){return!document.all&&document.getElementById;};function be(str){return/^\d+$/.test(str);};function Q(str){return/^[\w\.\-]+@[\w\-]+(\.[\-\w]+)+$/.test(str);};function R(str){var floatValue=parseFloat(str);return!isNaN(floatValue);};function aw(str){return!str.trim();};String.prototype.trim=function(){return this.replace(/^\s+|\s+$/g,"");};function bf(str){return/(^\d{5}$)|(^\d{5}-\d{4}$)/.test(str);};var defaultEnterButtonId=null;function aX(e){if(e.keyCode==13){var lnk=document.getElementById(defaultEnterButtonId);if(lnk){if(S())lnk.focus();else lnk.click();}}};function bm(buttonId){defaultEnterButtonId=buttonId;if(S())document.addEventListener("keydown",aX,false);else document.attachEvent("onkeydown",aX);};function P(ev){var objEvent=(ev==null?window.event:ev);var agt=navigator.userAgent.toLowerCase();var isIE=(agt.indexOf('msie')!=-1);var isFF=(agt.indexOf('firefox')!=-1);var code=0;if(isIE)code=objEvent.keyCode;else if(isFF)code=objEvent.which;if(!(code>=48&&code<=57))return false;};function T(ev){var objEvent=(ev==null?window.event:ev);var agt=navigator.userAgent.toLowerCase();var isIE=(agt.indexOf('msie')!=-1);var isFF=(agt.indexOf('firefox')!=-1);var code=0;if(isIE)code=objEvent.keyCode;else if(isFF)code=objEvent.which;if(!(code>=48&&code<=57)&&code!=46)return false;};function aK(num){var delimiter=",";num=num.toString();var a=num.split('.',2);var d="00";if(a.length>1){d=a[1];}var i=parseInt(a[0]);if(isNaN(i)){return '';}var minus='';if(i<0){minus='-';}i=Math.abs(i);var n=new String(i);var a=[];while(n.length>3){var nn=n.substr(n.length-3);a.unshift(nn);n=n.substr(0,n.length-3);}if(n.length>0){a.unshift(n);}n=a.join(delimiter);if(d.length<1){amount=n;}else{amount=n+'.'+d;}num=minus+amount;return num;};function aD(cookieName,showTranslate,hideTranslate,defaultPage){document.getElementById("tdMoreInfo").style.display="";if(document.getElementById("imgMoreInfoState").getAttribute("hidden")=="true"){if(cookieName=="DisplayLatestResultsMoreInfo"||cookieName=="DisplayPlayOnlineMoreInfo")document.getElementById("imgMoreInfoState").src='Images/user/BlueHide.gif';else document.getElementById("imgMoreInfoState").src='Images/user/hide.gif';document.getElementById("imgMoreInfoState").setAttribute("hidden","false");document.getElementById("tdMoreInfoText").innerHTML=hideTranslate;document.getElementById("tdMoreInfoContent").className="DisplayTD";setCookie(cookieName,true);}else{var show='<%=scTranslator.TranslateCommon("Show")%>';if(cookieName=="DisplayLatestResultsMoreInfo"||cookieName=="DisplayPlayOnlineMoreInfo")document.getElementById("imgMoreInfoState").src='Images/user/BlueShow.gif';else document.getElementById("imgMoreInfoState").src='Images/user/show.gif';document.getElementById("imgMoreInfoState").setAttribute("hidden","true");document.getElementById("tdMoreInfoText").innerHTML=showTranslate;document.getElementById("tdMoreInfoContent").className="NotDisplayTD";setCookie(cookieName,false);}};function aQ(sPaymentMethodID){var result=-1;sPaymentMethodID=sPaymentMethodID.substring(1);if(sPaymentMethodID.length>0)result=parseInt(sPaymentMethodID);return result;};function aR(sPaymentMethodID){var result=1;var cType=sPaymentMethodID.charAt(0);switch(cType){case CCSelect:result=SETTLEMENT_TYPE_CC;break;case NetellerSelect:result=SETTLEMENT_TYPE_NETELLER;break;case AditionalPaymentSelect:result=SETTLEMENT_TYPE_ADDITIONAL_PAYMENT;break;default:result=SETTLEMENT_TYPE_ADDITIONAL_PAYMENT;break;}return result;};function g(linkUrl,linkTitle){nameOf=navigator.appName;if(nameOf=='Microsoft Internet Explorer'){external.AddFavorite(linkUrl,linkTitle);}else alert('Hit CTRL-D to bookmark this page')}
