How to display an activity loader automatically with all ajax requests?

Posted by user257797 on Stack Overflow See other posts from Stack Overflow or by user257797
Published on 2010-05-03T15:27:35Z Indexed on 2010/05/03 15:38 UTC
Read the original article Hit count: 141

I am working on Ruby on Rails application, with Prototype. I want to display a loading div automatically with every ajax request and hide it on completion, without writing code for every ajax request in my application. Is there anyway to do this.

<div id="loader">Loading...</div>

© Stack Overflow or respective owner

Related posts about ruby

Related posts about ruby-on-rails