I make an ajax call to a servlet’s post method from my js file.
I wish to show an alert box till I get a response back.
How can i do it using ajax.
The alert window should close after I get response automatically.
ajax post request
$.post(fullpath, function(data) {
fnBookTicket(data);
});
Use a popup DIV instead and then close it…
CSS
HTML
JS
The popup shows before the ajax call and hides in the success handler, that is when data is loaded…