php - Load your custom classes in MODx Revolution -


i trying make simple class in modx getting 500 server error, ie example.

i created plugin , call on webpageinit

plugin

class foo {     function helloworld() {        echo 'hello world';     } }  

and created snippet , try

snippet

$foo = new foo;  

but getting internal server error 500, proper way this, or there autolader custom class?

i think documentation can give deeper explanation, making custom back-end programming.

https://rtfm.modx.com/revolution/2.x/case-studies-and-tutorials/developing-an-extra-in-modx-revolution


Comments

Popular posts from this blog

php - Admin SDK -- get information about the group -

dns - How To Use Custom Nameserver On Free Cloudflare? -

Python Error - TypeError: input expected at most 1 arguments, got 3 -