AjaxCore

This page discusses - AjaxCore

AjaxCore

AjaxCore

     

AjaxCore is a multi-purpose PHP framework that ease the development of rich AJAX ( Asynchronous JavaScript And XML ) applications, by generating the appropriate JavaScript code. AjaxCore takes all the dirty work of JavaScript code generation and provides a solid foundation. The concept is to extend a Generic AjaxCore class and defining methods that handle the AJAX driven events and binding them to HTML objects.

Read full Description

 

AjaxCore is released under Apache License V2.0, its is an open source project. It uses standard libraries of JavaScript for handling asynchronous XMLHttpRequest and getting Document Model Object. One point to note that you can bind events on HTML object which will execute server side code.

Uses

 

It binds the PHP functions and HTML events when JavaScript event is triggered.

It binds the PHP function and HTML object when JavaScript event is triggered and timer is expires.

It binds the periodically timers JavaScript event is triggered and it keeps reaping each timer expires.

To use the AjaxCore just write a class which extends AjaxCore and then write a function and bind it to the HTML object to handle ajax request. And this function called when JavaScript event is triggered. You can bind several JavaScript event to same PHP function. It is very simple just write an id of HTML element and then call it on PHP with $this->request['HTML_Element_Name'] method. You can also send an static value without  HTML Id by appending ('_') prefix to the HTML element. For example _ABC=XYZ, whereas ABC is the name of the variable and XYZ is its value.