-
MODX Staff
- 10,725 Posts
You should be able to see the 500 error either in core/cache/logs/error.log OR in whatever is configured as your PHP error_log (typically this is the Apache error log).
That said, loading MODX externally is not really recommended if you want to execute Snippets intended to be executed on a specific Resource. Many of them require the proper Context and Resource to be setup and loaded (with all the related data used in the request handling) in order to work properly.
Rather than struggling with this external loading scenario, why not create Resources in MODX to handle your AJAX requests? This makes things more consistent, reduces the possibility you might introduce additional attack vectors for hackers, and allows you to take advantage of the entire MODX framework more easily.
Well, loading modx externally it's not recommended ?, well why this tuto explain this, if it's more secure to do it under the modx way !
also, Thanks, I will change the way to perform json return (ajax dialog).
Well, it's done, ajax working under resources now, and... no prob.
Thanks !