How reuse custom code among projects using PHP natively?

Tuesday, November 3, 2015

I am not familiar with PHP and having a background in C#.



I would like to know if PHP offers a way to share custom code among projects natively in the language (targeting the latest version of PHP)?



As in C# there is the possibility to create a custom DLL, that can be included in other projects when needed in order to reuse some code.




  • Does PHP offer a similar feature?

  • Does PHP packages related on that?

  • Can PHP namespace be useful in this scenario?

  • What bout the use of include?

  • If PHP does not offer this support, which project/library can be used?



I understand there is the possibility to share common code from a versioning system such SVN and checkout sharedcode in each related project (as described in other answer on SO), but I am interested in the possibility in the language itself.

0 comments:

Post a Comment