Well, I'm not an expert on the subject so hopefully someone else will give a more complete answer, but the short answer is that you could look at ajax.php to see the server side stuff. In fact, you could put your response code in a plugin using hook ajax_start. On the browser side, it's handled in the .js files that are in the clientscript directory, so the templates just include a js file. I didn't follow all the code but it looks like the heart of it is a call to YAHOO.util.Connect.asyncRequest().
|