FAQ Database Discussion Community

autoloading nested classes with composer

I have created a very basic validator class. My base code is in a my src/ folder, which gets autoloader with "kevdotbadger\\Validator\\": "src/" this works fine, so that when I instantiate a new "kevdotbadger\Validator\ Validator is gives me src/Validator.php My Validator.php class then loads a bunch of sub-classes in my...

Wordpress plugin with classes, namespaces and psr-0 autoloading

I'm pretty new at this Wordpress thingy and I've now made my own theme and would like to create a plugin that handles my slideshow. (I have to teach this for some pupils later on, so I cannot just use an existing plugin) I have implemented the autoloader from http://www.php-fig.org/psr/psr-0...