Maybe you need to back up and explain what you are actually trying to accomplish without any decisions as to how to go about it?
What I'm trying to do is pretty usual stuff.
I've a JSP page with a form and a submit button in it. On clicking submit, it takes the form data and posts it to the server(struts 1.1) which in turn invokes a 3rd party web service.
The problem is that when the web service takes some time to respond, the users are quiet often clicking on the submit button more than once which is triggering off more requests.
Now all I wanted to do was provide the users some feedback while blocking the user actions.
I am currently displaying an animated gif on form submit, but once the form is submitted IE is stop the gif animation. So, I thought of AJAXifying the request so that the gif animation could continue.
But in fact, I couldn't do that because I had to show the response in a different JSP page that has much more functionality. (I just picked a wrong use case for AJAX).
Also, now, I don't need to do that since I'm able to run the gif animation by displaying the gif once again after the form submit which I'm doing using JQuery. Let me know if you have any better ideas.
This is what I've done: