[eluser]sorenchr[/eluser]
[quote author="Fabdrol" date="1296023360"]I think you could make this work with a hook, firing before the POST and GET data is sanitized.
Maybe you could do something like this:
- is $_POST populated?
- set a (global) variable $ajax_data to true
- set a (global) variable $ajax_method with the method name
- set a (global) variable $ajax_params with the parameters
then, in the routes.php file, you could set a dynamic route, something like this:
Code:
if($ajax_data) {
$params = implode('/', $ajax_params);
$route["$ajax_controller/$ajax_method"] = "ajax/$ajax_method/$params";
}
I've not tested it myself, but I suppose you could give it a shot...[/quote]
I guess this isn't going to be an easy one. Thanks for the help though.