
The rising popularity of AJAX in the "web 2.0" crowd brings some usability issues that may be unheeded by developers keen to use the latest and greatest technology.
As a brief overview : AJAX is a combination of Asynchronous Javascript and XML (with a helping of DOM tree manipulation). Essentially these elements combine to allow the developer to create a dynamic web page that does not require a full page refresh.
Now, when designing these great new applications there are a couple of rules that must be followed else the application confuse the user to never be used again. (Hardly a model for success in the web world!).
Rule 1 : test how your application handles a "Back" button event
Pretty simple really, if you are updating information on the server side and the user then presses the back button does your application roll back to a previous state or does it crash? Some basic testing can catch any true nasty errors but the subtle data errors of double committing are numerous and difficult to find.
Rule 2 : handle server errors gracefully
The first A of AJAX is for Asynchronous. An undefined duration of time will pass from a user action to a visable result and that time can be affected by server load, network traffic, the whole chain of usual communication errors. What does the application do on a network time-out? How does application stability suffer? How do you notify the user? These are all issues that require forethought to prevent user frustration.
Rule 3 : check for malformed data
Data from the server may not be correctly formed and in some cases could be modified by someone in the middle. Ensuring the application can handle malformed data or detecting any error before rendering time is an even better plan. A potential line of action is to checksum the data that is transmitted to the client. A quick md5 sum would provide a nominal level of security.
Rule 4 : provide degraded functionality for older browsers
Unless you know exactly what browser the user will have when using your site be sure to degrade your functionality so that older browsers can still use your product. A great majority of web surfers will probably use a recent browser but one needs to be wary of the growing numbers of mobile device (PSP, mobile phones, PDA's) users. Don't assume a mobile user would never use your application!
Rule 5 : is AJAX required?
As with all new technologies that are shiny and new there is a desire to integrate it into a project "because it is cool". Avoid this at all costs! AJAX can definitely make a site more functional and enjoyable for the end user but it can also cause usability nightmares if implemented without a real need. AJAX can turn a typical webform entry process into a dynamic desktop application. It is possible to correct user error as they are entering data can improve workflow efficiency. Applications can update information in almost real-time to provide critical data to the user without their interaction. The mind gibbering tweaks one can apply to any website are endless.
A critical analysis of how the application works better with, and without, AJAX should be examined by Designer, Architect and Developer. Once the value of using the technology becomes evident it should be implemented and throughly tested. Technologies like AJAX have to the power to make the web a true interactive system, used with care they can improve our daily web usage; used incorrectly, and without reason, they can make our life a lot less enjoyable.