I really don’t know much about this at all
Maybe this can be used:
http://wiki.modxcms.com/index.php/Use_AJAX_with_modxAPI
-
MODX Staff
- 10,725 Posts
Just create a document in MODx that accepts your Ajax request and produces the response you want. You can use a blank template and a snippet to produce whatever kind of response you want: HTML, JSON, XML, etc., and still have access to everything you normally would in MODx documents.
I am not a Mootools expert, but I guess your code trying to accomplish the AJAX has some problems. Take a look at this Mootools 1.2 AJAX-tutorial by David Walsh:
http://davidwalsh.name/basic-ajax-requests-mootools
Oh ... and make sure you use Mootools 1.2 of course, because Mootools 1.1 has a quite different syntax.
Good luck,
Bogdan