PSR 4 and composer .... autoloading

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
User avatar
gautamz07
Forum Contributor
Posts: 331
Joined: Wed May 14, 2014 12:18 pm

PSR 4 and composer .... autoloading

Post by gautamz07 »

Hey just saw this tutorial online HERE https://www.youtube.com/watch?v=VGSerlMoIrY ,

so all modern frameworks or PHP projects use PSR-4 and composer to auto-load ?

basically my question is about autoloading and what is the best mechanism to autoload in PHP ?
User avatar
Celauran
Moderator
Posts: 6427
Joined: Tue Nov 09, 2010 2:39 pm
Location: Montreal, Canada

Re: PSR 4 and composer .... autoloading

Post by Celauran »

Set up PSR-4 autoloading through Composer and you're done. That really is the standard.
User avatar
gautamz07
Forum Contributor
Posts: 331
Joined: Wed May 14, 2014 12:18 pm

Re: PSR 4 and composer .... autoloading

Post by gautamz07 »

Thanks ... all setup https://github.com/gautamz07/PSR-4/ :D , just a simple example that shows how to use composer and PSR-4 to autoload .
Post Reply