AJAX XML and JSON - Javascript

The first time I decided to be creative about IPC is some twenty years ago. I needed different applications running on the same Unix workstation to cooperate and wondered what 'the language' over the IPC wire should be like. Not hindered by too much technical background I thought I should have a look a Postscript. After all this too was a matter of one application asking another to provide some service. I think I understood the idea and decided I needed a language and an interpreter for it. The language, just plane ascii, could be sent from one application to the other and the receiving application would execute the stuff rather than decode it.
The years thereafter I had a lot more usage for my invention. A project or five later I was dealing with GUI's and RDBMS'es and these were spread over some 40 countries. Not too surprisingly the exchange of information between the databases was message based and most if not all messages where in 'my language'. Then in some particular application we needed an algorithm that we knew was going to need change regularly. Ahhh.. of course. We implemented the algorithm in 'my language'. Hence we could store it in the RDBMS and edit it using a 'normal' database in-out type of application. Releasing the algorithm to the 40 sites, was then already solved as well. The algorithm was data no different from other data...

and then came XML

And clients / employers started to 'ask' me about it. In the beginning I dared to say that I had something better in mind. But I learned to keep my mouth shut for simple reasons: I need an income.

and then came JSON

and I can put a smile on my face again. We can not only send JSON style Javascript but any Javascript from the server to the client. In the client the stuff is executed versus decoded. try my ajax using XML or using JSON - javascript

Try to run the above XML based AJAX both on Internet Explorer and on Mozilla Firefox and notice that the same XML builds different DOM trees in those two browsers. Further more you should know that at the API level the DOMs differ too...

Learn more:
A starting point for JSON
A starting point for AJAX
And a nice discussion on the same topic you find here.

Theo van Eijndhoven
August 2006

I'm not saying that web sites from now on must use AJAX and must use JSON. Only use AJAX if you need to. My first objective always is to try and adhere to the design filosofy of things. In case of the web stuff this is a very simple idea: request a page and get it. More is not needed.