5
3
|
I understand how to use javascript to change the cursor to busy while the page is making and ajax call.
However I have a page that does not use ajax, it uses a postback to reload the page. However the load is rather data intensive and it takes a few seconds. During this time the user can still click on the page. I want to turn the cursor to "waiting" so the user does not try to click on the page.
For example I have a couple of dropdowns that cause postback. I make a selection and the page loads for 3 seconds. While it loads I would like the cursor to turn to waiting so the user does not try to make a selection on a second dropdown until the page reloads.
Is this possible?
Additional Info: (simplified version of my setup)
I have a masterpage:
|
and then a page that uses the master page:
ID="Content1" ContentPlaceHolderID="MAIN" Runat="Server">
runat=server id="tb_simple_search_table" cellpadding = 0 cellspacing = 0>
It's those Dropdownlists that are doing the postbacks during which I want the wait cursor. – kralco626 Oct 29 '10 at 17:08
| |||
I mean really, anytime the page is loading it would be nice if I could get the wait cursor, regardless if why it is waiting... – kralco626 Oct 29 '10 at 17:09
|
3
|
you can add a handler to the form's
submit event.CSS
JavaScript
here we're ensuring our method gets called if
submit() is called in js like the drop down does when it causes a postback. this should also catch any other instances of the form submitting. | ||||||||||||||||||||
|
6
|
I am not certain if this is the best or most efficient method but if you want to change the cursor to show the page is busy after the button click the following jQuery should do the trick:
| ||||
|