The trouble with Ajax

The Web and AJAX have many deficiencies and much more needs to be done, according to a keynote speaker at The Rich Web Experience conference.


The Web and AJAX have many deficiencies and much more needs to be done, according to a keynote speaker at The Rich Web Experience conference.

Douglas Crockford, an architect at Yahoo and creator of JSON (JavaScript Object Notation), gave a critical presentation on AJAX (Asynchronous JavaScript and XML) and the Web entitled: "The State of AJAX."

Crockford said:"The sad thing was the Web was a step backward in terms of interactivity."

He argued it was a false hope to believe Java would fix the problem with applets. "Unfortunately, Java was a huge failure. It completely collapsed. It didn't meet any of its goals." Java's write once, run everywhere promise was not kept; it had an unworkable security model and a tedious UI model. He added, however, Java did become very successful on the server.

JavaScript and then XMLHTTP had to request for communication from the browser to the data server. "It was really Microsoft that created all the components that AJAX needed" Crockford argued.

AJAX applications are highly interactive, highly social, easy to use, and offer great network efficiency, according to Crockford. "The big problem is that it is too damn hard to write these applications."

"The most interesting innovation in software development in 20 years has got to be the mashup" which showed the benefits of distributed programming. "Unfortunately, mashups are insecure" said Crockford, with components unable to be protected from each other.

In Crockford’s opinion the model in the browser is fully broken and needs to be fixed. "The Web is an exploit waiting to happen."

Crockford then turned his attention to problems with the other web technologies. "JavaScript is a deeply flawed language. But to its credit, it's working really, really well in an environment where Java failed." The planned JavaScript 2 upgrade will be similarly flawed making “the language considerably more complicated."

Crockford raised questions about whether HTML it is a document format or an application delivery; it has low graphical ability and is missing a compositing model. Within AJAX , HTML there needs to be an application delivery format. XHTML was supposed to replace HTML, but it died because it was too brittle according to Crockford.

CSS (Cascading Style Sheets) presents a styling layer in the browser, but it is slow, complex, and incredibly fragile. "It surprises me that there is not a greater call for its replacement."

XML is complicated and inefficient, said Crockford. "Fortunately, XML has been replaced by JSON. This gives me some confidence that we can fix the standards in the Web. This is our first success at that."

Crockford urged standardisation and uniformity in browsers. However, he pointed out, there are computers not capable of running the latest browsers.

If the Web is unable to repair itself, it could be replaced with a proprietary system such asMicrosoft's Silverlight or Adobe's AIR (Adobe Integrated Runtime). Proprietary systems do present obvious advantages, but people like open systems and are suspicious of proprietary systems.

Crockford added that he used to think the browser was the most hostile programming environment ever devised, but then he found out about mobile programming. The mobile industry has had its own failed experiments.

"Despite all of its problems, AJAX works. So we're looking at a mobile Web now" Crockford said.

Earlier on Thursday, Kevin Hoyt, platform evangelist with Adobe Systems, emphasised the concept of experience as critical for Web development. Experience matters to business, he stressed."Seventy-two percent of shopping carts abandoned because of poor user experience."

He urged developers not to disregard what they have learned from developing desktop applications when they start to build for the Web. It is OK to use desktop metaphors in Web apps, such as widgets, he said. "It's OK to think inside the box," said Hoyt. Customers, he said, want a personal relationship with a brand.

"Recommended For You"

Sun eyes a JavaScript alternative to AJAX Tibco open-sources AJAX mashup tool