Search
in english whole site
»
Home·Programming·AJAX·AJAX Introductiondeutsch·english·français
UserEnlargeHigherLower
StatisticsMinimizeHigherLower
» Hits: 150326  (details)
» Distinct visits: 34183 (1.1 Hit/visit)
» Bots visits: 113267 (Hits: 75.3%)
» Your hits in this session: 1
Contact & CommentsMinimizeHigherLower
» Visitor's comments
» Contact
AJAX Introduction
What is AJAX

AJAX is a cool name for a very simple technique: asynchronous server requests. Which is again a complex name to say: possibility after a webpage has been loaded to make requests to the server. The main use is for forms that can submit data to the server and display results without requiring the whole page to be reloaded. This is on one hand quicker, as only key information are transmitted, and not the whole data that did not change, and on the other hands looks more like a normal application (see the demo).

Technically, this is done by using a javascript to make a request to the server - then the server answers to the javascript, and finally the javascript modifies the page to display the results. Therefore AJAX applications have 2 components:
  • A client side javascript, and,
  • A server side software to answer the requests.
A simple demo

You can see below a simple demo of AJAX. Type some text in the left field. Then click on the button. The AJAX javascript will show you what it is sending to the server. When the server answers, the script will show you the raw answer, and finally will write is in the right field.
Type here and clickServer answers here



Implementing AJAX

AJAX is fully implemented in CSE Display, a PHP object to create webpages available here. However, for those who want "only" the AJAX components without the whole object, the necessary elements can be downloaded here.

The elements required for AJAX implementation are:
  1. A way to create an event that lauches the request,
  2. The javascript to react at the event and send the request,
  3. A server side program to handle the request and send the answer,
  4. A javascript to interpret the answer and,
  5. An element on the page that will display the answer.
How to create and combine those elements is explained here.
Made with CSE_CMS, © CSE, 2008-2021