Posted By

Piotrek290 on 01/10/10


Tagged

ajax bar loader


Versions (?)

Who likes this?

1 person have marked this snippet as a favorite

wirenaught


Ajax loader bar


 / Published in: JavaScript
 

URL: http://mini.dealis.pl/js-simple-loader/

  1. $.ajax({
  2. url: [
  3. 'data/books.xml',
  4. 'data/time.php',
  5. 'soq.2.2.2.js',
  6. 'data/mootools.js',
  7. 'data/other.php',
  8. 'data/wait.php',
  9. 'data/dojo.js'
  10. ],
  11. type : 'post',
  12. time : 1000,
  13. group : true,
  14. success : function(req, num, all){
  15. var percent = Math.ceil(num/all*100);
  16. $("#loader").css("width:"+percent+"%");
  17. },
  18. successAll : function(){
  19. $("#loader").anim("background:#87A06E;", { time:200 });
  20. $("#bar").anim("top:-30px;");
  21. }
  22. }).run();

Report this snippet  

You need to login to post a comment.