Section 1.3. TurboGears, Ajax, and Web 2.0


1.3. TurboGears, Ajax, and Web 2.0

Recently, there has been a lot of hype about web 2.0 applications and Ajax. In a lot of cases, the hype has passed out of the realm of technical discussion into pure marketing jargon. There are a lot of people selling pretty animations as though they were revolutionary. But, underneath it all, there is a real revolution happening. On the technological side, JavaScript now works reliably to send and retrieve data from the server and to add it to an existing page in real time.

Ajax is shorthand for Asyncronous JavaScript and XML, but it has come to be used to describe a variety of techniques that allow the JavaScript to talk to your server and dynamically update your page in real time. Sometimes, XML is not involved; the server response can be plain HTML or serialized JavaScript objectsit doesn't matter, we still call it Ajax.

Technology aside, Ajax's real impact is that it is enabling a revolution in user interface design for the web. For more than 10 years, the dominant paradigm of web development has been this: "Serve up a series of dynamically generated pages." Now we're starting to see that user interaction does not need to be chunked up into whole page sections. Ajax-enabled pages have code to send requests for dynamic updates to the server, receive live responses, and update themselves automatically. This really is a revolution in user interface design, and TurboGears includes MochiKit JavaScript library, and a variety of prebuilt widgets to help you take advantage of everything that Ajax can bring to your application.

Unfortunately, revolutions take work, and this one is no different. Hopefully, nobody has to die, or go without food, or take 40-hour guard shifts, or do any of the stuff that real revolutionaries do. But, you will have to write JavaScript, debug it on different browsers, and understand a little bit about the Document Object Model (DOM).

Fortunately, the MochiKit makes all of this easier. So, your personal revolutionary statement won't end up costing your lifeor even a good night's sleep.




Rapid Web Applications with TurboGears(c) Using Python to Create Ajax-Powered Sites
Rapid Web Applications with TurboGears: Using Python to Create Ajax-Powered Sites
ISBN: 0132433885
EAN: 2147483647
Year: 2006
Pages: 202

Similar book on Amazon

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net