It's better when it's simple

User Tools

Site Tools


ajaxloader Plugin

Compatible with DokuWiki

No compatibility info given!


Last updated on

This extension has not been updated in over 2 years. It may no longer be maintained or supported and may have compatibility issues.

A CosmoCode Plugin


Install the plugin using the Plugin Manager and the download URL above, which points to latest version of the plugin. Refer to Plugins on how to install plugins manually.


The ajaxloader plugin aids in implementing both sides of an AJAX call: Calling and providing the endpoint. You can freely combine both parts with each other or with DokuWiki’s own facilities.


The plugin provides two functions: doku_ajax(call, params) and serialize_form(form). doku_ajax should be used as a constructor. It expects the name of the ajax call in the format »plugin_PLUGINNAME« or »plugin_PLUGINNAME_CALLNAME«. You may optionally specify a hash with request parameters common to all requests made with this AJAX object. If you provide a form object, it is automatically serialized using serialize_form().


The plugin provides a simpler way of developing the endpoint than hooking AJAX_CALL_UNKNOWN: Just create a file ajax.php in your plugin directory. If you need multiple endpoints, create a directory ajax/ instead and drop files CALLNAME.php in it. You may expect the same preprocessing as through lib/exe/ajax.php, only a bit faster. Moreover, if you provide an array called $AJAX_JSON, it is automatically echoed in JSON-encoding afterwards.

plugin/ajaxloader.txt · Last modified: 2021-01-14 11:44 by annda

Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Share Alike 4.0 International
CC Attribution-Share Alike 4.0 International Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki