I've written a few, but there's a whole bunch out there (http://
docs.jquery.com/Tutorials).
Using Ajax to validate forms:
http://jqueryfordesigners.com/using-ajax-to-validate-forms/
Ajax'ifing forms (screencast):
http://remysharp.com/2007/03/05/jquery-ajaxed-forms/
What you're after boils down to this (though very simply):
$('#waitingblock').html('img src=loading.gif /');
$.ajax({
url: 'myurl.php',
data: 'action=do-stuff',
success: function () {
$('#waitingblock').empty(); // remove the loading image
// do stuff.
},
error: function () {
$('#waitingblock').empty();
// let the user know something went wrong
}
});
On Feb 18, 8:18 am, gh0st [EMAIL PROTECTED] wrote:
One of the things that is frustrating me in learning jQuery is that
there isn't enough examples, case-studies or tutorials on how to use
the .ajax call; most web pages I've seen seem to be for the .load
or .get.
That being said, can someone post a very basic Ajax call complete with
a loading gif?
Also, does anyone have any links/resources to case-studies/examples of
Jquery and the .ajax call?
With thanks.