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>
You may want to check out this article:
Basically you can handle it with:
Where
startLoadingandstopLoadingare callback functions that show/hide your activity indicator.