Posts Tagged HTML
Getting Introduced To AJAX
Asynchronous JavaScript and XML commonly known as AJAX. This is not a new programming language, but a new way to use existing standards.
Why Ajax?
The only and the most important answer is that an alternative to flash. No flash so Ajax. In other words we can say AJAX has two huge benefits:
1. Speed and invisibility makes for a very slick user experience.
2. The smaller server resources footprint helps server scalability.
With AJAX, Internet applications can be made richer and more user-friendly. when your customer clicks on something on an Ajax driven application, there is very little lag time. The page simply displays what they’re asking for.
It is widely accepted that fast-loading pages improve the user experience. In recent years, many sites have started using AJAX techniques to reduce latency.
History of Ajax
The start of 2005 saw the rise of a relatively new technology, dubbed “Ajax” by Jesse James Garrett of Adaptive Path. Ajax stands for Asynchronous JavaScript and XML. In a nutshell, it is the use of the nonstandard XMLHttpRequest() object to communicate with server-side scripts. It can send as well as receive information in a variety of formats, including XML, HTML, and even text files.
How does AJAX WORK?
The Ajax engine works within the Web browser (through JavaScript and the DOM) to render the Web application and handle any requests that the customer might have of the Web server. The beauty of it is that because the Ajax engine is handling the requests, it can hold most information in the engine itself, while allowing the interaction with the application and the customer to happen asynchronously and independently of any interaction with the server.
Ajax’s most appealing characteristic, however, is its “asynchronous” nature, which means it can do all of this without having to refresh the page. This allows you to update portions of a page based upon user events and provides one of the cornerstones of Rich Internet Applications (RIA) referred to in discussions of “Web 2.0.”
How AJAX is different ?
An Ajax application eliminates the start-stop-start-stop nature of interaction on the Web by introducing an intermediary — an Ajax engine — between the user and the server. Instead of loading a webpage, at the start of the session, the browser loads an Ajax engine — written in JavaScript and usually tucked away in a hidden frame. This engine is responsible for both rendering the interface the user sees and communicating with the server on the user’s behalf. The Ajax engine allows the user’s interaction with the application to happen asynchronously — independent of communication with the server. So the user is never staring at a blank browser window and an hourglass icon, waiting around for the server to do something.
Getting Started with AJAX
Ajax is not a technology in itself, but a term that refers to the use of a group of technologies. Ajax uses a combination of:
- HTML and CSS for marking up and styling information.
- The DOM accessed with JavaScript to dynamically display and interact with the information presented.
- A method for exchanging data asynchronously between browser and server, therewith avoiding page reloads. The XMLHttpRequest (XHR) object is usually used, but sometimes an IFrame object or a dynamically added <script> tag is used instead.
- A format for the data sent to the browser. Common formats include XML, pre-formatted HTML, plain text, and JSON. This data could be created dynamically by some form of server-side scripting.
The DOM plays into Ajax in a number of ways. How you use the DOM depends a good deal on how you handle the content returned from the server. You can treat the con¬tent as simple text using the responseText property of the server response, or you can treat it as XML using responseXML. Assuming the content you pull back from the server is an (X) HTML snippet and you’ve gotten it as responseText, you could drop that content into a particular spot on the page using innerHTML. On the flip side, if the content you pull back is XML and you’ve gotten it as responseXML, you can traverse its DOM, cherry-picking or performing functions on the elements, attributes, and text nodes.
Although we are just beginning to realize its full potential, the proven success of famous AJAX-based projects like Google Maps, Google suggest or gmail are few real time examples which signifies that this is not just another media hype, but rather a promising technology that may change web-applications as we know them.
Limitation of Ajax
AJAX will not work in all web browsers. As its name suggests, AJAX requires JavaScript. This alone means that AJAX applications will not work in web browsers and devices that do not support JavaScript. For this reason it is not accessible to many typical Web users
This is one of the limitations of the technology but as it’s having so many features the technology has many drawbacks too.
Future of Ajax:
AJAX is an extension of DHTML programming, adding the capability to dynamically send and retrieve data from the web server in response to user actions.
The biggest challenges in creating Ajax applications are not technical. The core Ajax technologies are mature, stable, and well understood. Instead, the challenges are for the designers of these applications: to forget what we think we know about the limitations of the Web, and begin to imagine a wider, richer range of possibilities.
AJAX is a tool that web developers can use to create smarter web applications that behave better than traditional web applications when interacting with humans.
Ajax has changed the face of the web forever. Save for some of the browser enhancements and a few other technologies, I dare to say that it’s had the most significant impact on the way we use the internet in its short life.
We are web development company which uses this as one of the technology. So for any further inquiries or real time projects you can contact marketraise
