Countdown

Descargar Countdown.js

Ejemplo de la clase Countdown en javascript para mootools 1.2.3




<script src="/examples/js/mootools-1.2.3-core.js" type="text/javascript"></script>
<script src="/examples/js/mootools-1.2.3.1-more.js" type="text/javascript"></script>
<script src="/examples/js/Countdown.js" type="text/javascript"></script>
<script type="text/javascript">
    new Countdown($('counter'), {
      'decimals' : '3',
      'onComplete' : function() {alert('finalizado!');},
      'onStep' : function(target, show) {
        if(show < 5) {
           target.setStyle('color', '#f00');
         }
         else {
           target.setStyle('color', '#000');
         }
       }
     }).start();
</script>