AJAX in plugins
e107 Wiki: English | Русский | Deutsch | Français | Magyar | Português | Български | Česky | Nederlands | Ελληνικά | Italiano | Norske | Polska | Slovenščina | Español | Svenska | Translate: Wiki | Page
Note: This page applies to E107 version 0.7/1.0 only - version v2.0 will include support for Ajax using the jquery and/or Prototype frameworks.
IMPORTANT: E_Token - Technical Notes on the e_Token System - How to Avoid Access Denied In Your Plugins & Themes.
The XMLHttpRequest object is a key player in AJAX. Using this object the user's browser is able to make a page request in the background and show the data. This translates to the user requesting some data and receiving it without having to reload the whole page. This is what makes the web application more like a standard desktop application. There are two flavours of this object, XMLHttpRequest, which is supported in browsers such as Firefox 1.5+, Opera 7.0+, Safari and Internet Explorer 7.0. For earlier versions of Internet Explorer the XMLHttpRequest object takes the guise of the Microsoft.XMLHTTP object.
Creating an XMLHttpRequest Object
This does leave the problem of how we should allow our end user to look at the page regardless of their web browser. This can be achieved in a number of ways. I will show you the way that I prefer but there are others.
In fact, it's even easier to do this in e107: