I read a few brief descriptions of AJAX. All of the material showed request/response type samples. How does the Asynchronous part of Ajax work. Let's say I wanted to display a "Times Square" news reader over the top of page. Would this be a good application?
Also, what kind of latency might I expect downloading the Ajax engine? Once downloaded will it be cached somewhere? Plug-in available or needed?
Using the XMLHttpRequest object, we are able to send a request off to the server without interrupting the user. Rather than do a full page repaint, we can get a small chunk of data back and then update the DOM. To me, it's the A in Ajax that makes it particularly interesting to developers. That said, I actually have used XHR to communicate in a synchronous fashion...
News apps are a great spot for Ajax - check out digg. Ajax isn't an engine per-say, it's just taking advantage of new browsers implementing the XMLHttpRequest object. Ajax relies on existing technologies (HTML, DOM, XHR, etc) which are already in the browser - no plugins needed!
Nate Schutta<br />Coauthor of <a href="http://www.amazon.com/exec/obidos/redirect?link_code=ur2&camp=1789&tag=ntschuttacom-20&creative=9325&path=tg/detail/-/1590595823/qid=1127567332/sr=8-1/ref=pd_bbs_1?v=glance%26s=books%26n=507846" target="_blank" rel="nofollow">Foundations of Ajax</a><br />My blog: <a href="http://www.ntschutta.com/jat/" target="_blank" rel="nofollow">Just a Thought</a>
Thank you Nate. I think I understand that Ajax doesn't rely on a backend server of any type either. It appears that the data exchanged is fairly raw. I am not familiar with XMLHttpRequest, I am bouncing back and forth to an XMLHttpRequest and Struts and this site trying to get caught up. However, if I were to implement a streaming news reader, for instance, I would rely on native HTTP chunking protocol between my server and Ajax client and I would block in a 'get loop' waiting the next feed? I handle the headers myself? Also, it looking like the document can be very raw, not necessarily XML as the object name implies?