# Providing feedback to users

**URL:** <https://www.ruby-forum.com/t/providing-feedback-to-users/186195>\
**Category:** Rails\
**Created:** [April 1, 2010, 11:45pm UTC](https://www.ruby-forum.com/t/providing-feedback-to-users/186195 "2010-04-01T23:45:46Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![mstoth](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/54ee81/32.png) [@mstoth](https://www.ruby-forum.com/u/mstoth)\
**Post date:** [April 1, 2010, 11:45pm UTC](https://www.ruby-forum.com/t/providing-feedback-to-users/186195/1 "2010-04-01T23:45:46Z")

</div>

I have an application which does some time-consuming work after a form  
is submitted.  
I’d like to have a little message saying “please wait” but I’m not  
sure how to implement that.

I’m thinking somehow you have to send a page to the browser from the  
method that is being called by the form.  
Sounds like a basic thing but I’m kind of new to RoR.

Any ideas?

-Michael

---

<div class="post-metadata">

**Author:** ![mstoth](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/54ee81/32.png) [@mstoth](https://www.ruby-forum.com/u/mstoth)\
**Post date:** [April 2, 2010, 10:24am UTC](https://www.ruby-forum.com/t/providing-feedback-to-users/186195/2 "2010-04-02T10:24:50Z")

</div>

It can by manage if you you using AJAX, and it’s many ways to do it,  
there one:

just show some

pleas wait
  
on ‘ajax start’ event and hide this one on ‘ajax end’ event.

If you choose jqure ([jquery.com](http://jquery.com)) it would look like:

$(“#loading”).ajaxStart(function(){  
$(this).show();  
});

(“#loading”).ajaxStop(function(){  
$(this).hide();  
});

[http://api.jquery.com/ajaxStart/](http://api.jquery.com/ajaxStart/)  
[http://api.jquery.com/ajaxStop/](http://api.jquery.com/ajaxStop/)

---

<div class="post-metadata">

**Author:** ![mstoth](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/54ee81/32.png) [@mstoth](https://www.ruby-forum.com/u/mstoth)\
**Post date:** [April 4, 2010, 4:38am UTC](https://www.ruby-forum.com/t/providing-feedback-to-users/186195/3 "2010-04-04T04:38:06Z")

</div>

Thank you. I implemented something similar to what you described and  
got it to work.  
Many thanks.

-Michael
