/*var newNum=startNum;
var sturie=false;
window.addEvent('domready', function() {
						
						 $('num').set('html',numberFormat(newNum));
					 
						sturie=updateCounter.periodical(1000);
						
						}); //domready

var updateCounter = function()
							{
								if(newNum!==0){ 
									if(metodo==='countdown'){
										newNum-=1;
									}else {
										newNum+=1;
										}
									$('num').set('html',numberFormat(newNum));
									
								} else { 
									$clear(sturie);
								}
							}


function numberFormat(num, decimals, thousands_sep) {
	
			decimals = Math.abs(decimals) + 1 ? decimals : 2;
			
			thousands_sep = thousands_sep || '<span class="black">.</span>';
 
			var matches = /(-)?(\d+)(\.\d+)?/.exec((isNaN(num) ? 0 : num) + ''); // returns matches[1] as sign, matches[2] as numbers and matches[2] as decimals
			var remainder = matches[2].length > 3 ? matches[2].length % 3 : 0;
			return (matches[1] ? matches[1] : '') + (remainder ? matches[2].substr(0, remainder) + thousands_sep : '') + matches[2].substr(remainder).replace(/(\d{3})(?=\d)/g, "$1" + thousands_sep) /*+ 
					(decimals ? dec_point + (+matches[3] || 0).toFixed(decimals).substr(2) : '')*/;
		}
        
		
		
*/