Código Javascript:
Ver original
function barra(){ var tiempo = new Date(); var segs = "<? echo $segs; ?>"; var am = "<? echo $city['build_'.$encon.'_cons_time']; ?>"; var re = tiempo.getTime()-am; var cien = re*100; var por = cien/segs; document.getElementById('ampliando').style.width=''+por+'%'; } setInterval("barra()",1000);