If you’ve been using the Internet for a while, you’ll have noticed a slight change in the way certain online services have provided content, in the past 1-2 years. A sort of mini-revolution is going on, leading to the term “Web 2.0” to describe this new breed of web-based services. A lot of exciting things are promised, and some have been demonstrated and are in semi-wide use.
Perhaps the best example is Gmail. While most of the buzz surrounding it during its launch was the then-unprecendented storage allowances, the service also implements AJAX to improve the quality of the application and make it seem more like a desktop application than a web service. For example, when you start typing in someone’s e-mail address in the “To:” field while composing a message, you’ll find that Gmail pops up a list of possible matches as you type, allowing you to quickly select the intended recipient – this is AJAX at work, and basically it allows your web browser to communicate with the web server to update and provide information to parts of the web page without having to reload the entire site, thus making it seem more like a regular program.
The power of AJAX was quickly apparent to many web developers and since then, many new and interesting applications based on its principles have been made. Indeed, WordPress, what I use to run this site, also nicely implements AJAX in its admin pages. It seems likely that AJAX will continue to permeate more and more websites.
With this proliferation should come caution. The potential for problems is high, not necessarily because of AJAX itself but because of the ways it can be implemented. First and foremost, AJAX should not be put into a website just for the sake of having AJAX there – sometimes simplier is better, and if it isn’t needed maybe it shouldn’t be there. Additionally, AJAX should probably not be required for the website to work – thankfully, major services like del.icio.us and GMail have followed this unwritten law; it’s not unlike the unwritten mantra for plain old Javascript and websites.
Secondly, security is an issue, as outlined in this article. In it, Stewart Twynham remarks that because AJAX is a new and developing technology, clear design patterns do not exist and thus this increasing the chance for poor coding that inherently leads to security and other problems. Additionally, the increased amount of scripts and code and the way they’re laid out can lead to complexity issues – thankfully, there is help available now. With the recent release of Yahoo! UI Library and the Google Web Toolkit, AJAX development can be greatly simplified – it should be noted there are many community-driven AJAX and general JavaScript frameworks and libraries also available that do the same thing, and sites dedicated to making AJAX coding more efficient exist. With the popularity of AJAX, such developments were inevitable; however, since AJAX is still relatively new and is still in the process of growing and being standardized by the W3C, a cautious approach is still needed here. (The slow response of the W3C to AJAX and other technologies is however, another topic.)
Lastly, user interface requirements must be considered – though AJAX is mainly used to improve interactivity and thus user experience, there are ways that it can be detrimental to user experience. With AJAX, there is increased potential for making a web application that doesn’t make its state known to the user, causing confusion and annoyance, and worse still, possible data loss. Your best bet here is to have someone experienced with UI design take a look at what AJAX is doing to the interface.
So in short, AJAX is a promising technology, and if you haven’t heard a lot about it already, you will be soon as it slowly becomes more and more prevalent on the Internet. Let’s hope web developers implementing it follow good coding practices.