Where can I use AJAX ? [Part 1]
Many use the places where you cannot use AJAX as a negative point for AJAX, while it is better to know that every technology isn't good for everything and everywhere. If C++ is excellent why there is Java, Delphi, Visual Basic ... and so on ? Every technology have its good and bad point, and the places where it should be used and where it cannot.
Same for AJAX, I was asked today about using AJAX inside a form. This case I find pretty interesting to show that we should study every case seperately and see if this technology fit better or another one. The answer can't be fondamental and without any real technical background. Ok here is the situation.
The application is fully web based will try to read data from barcode, and for every entry it creates a dynamic form including a textbox with the number retrieved from barcode and a select box with data from database. The idea behind thinking of AJAX is that the data retrieved from database could be loaded on demand. Everything is clear until now I hope.
But the situation is, it is a real application and the user when it start using the barcode he have to finish scanning a set of papers, it could be hundreds or thousands and then affect an entry from database to each number. So if I use AJAX I'll have to load data with each entry, even if its using cache.
So it was better to load data first, even that it will take time to load the page in the first time, and don't let the user wait for data to be retrieved with each dynamicly created inputs.
If you have similar experience with AJAX and real applications it is interesting to share with the AJAX community. So we won't have frameworks and implementations only but we'll have better experience for building more useful solutions.











AJAX Magazine's RSS