Skip to content

adressler/contao-ajax_json_response

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 

Repository files navigation

AjaxJsonResponse (Contao extension)

Enable JSON response for AJAX requests (Contao extension)

Compatibility

Contao 3.1

License

LGPL

Known Issues

JSON response has mime type text/html instead of application/json

Setup

Copy contents to system/modules/AjaxJsonResponse/

Initiate a XMLHttpRequest. Contao will then deliver the site contents as JSON object. This extension will add .json to your page template file name: If your template is called fe_page.html5, Contao will use fe_page.json.html5 as your JSON template. Feel free to copy and adapt the delivered template within your templates directory.

The JSON response object will contain most of the information of your html page, e.g. all sections and custom sections as well as the page class.

This extension does not include javascript code to handle the JSON response. You will have to add appropriate frontend scripts to ajaxify your Contao site.

Feel free to comment or discuss :)

About

JSON response for AJAX requests (Contao extension)

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Languages