Posted By

cfleschhut on 04/11/10


Tagged

javascript loading mootools dots


Versions (?)

MooTools Dots Loading Indicator


 / Published in: JavaScript
 

URL: http://jsfiddle.net/EXbB3/

  1. window.addEvent("domready", function() {
  2. var log = $("log");
  3. var count = 0;
  4. var addDot = function() {
  5. if (count < 20) {
  6. this.set("text", this.get("text") + ".");
  7. count++;
  8. } else {
  9. log.empty();
  10. count = 0;
  11. }
  12. };
  13. var myPeriodical = addDot.periodical(50, log);
  14. (function() { $clear(myPeriodical); }).delay(4000);
  15. });

Report this snippet  

You need to login to post a comment.