DEV Community

Discussion on: PHP - Create your own dotenv to loads environment variables from .env file

Collapse
 
benhickson profile image
Ben Hickson

Where do we put this class file, and how do we require it into the application?

Collapse
 
fadymr profile image
F.R Michel

you use composer ? or without composer ?

Collapse
 
benhickson profile image
Ben Hickson

Ideally both ways? Sometimes I can, some projects I can't.

Thread Thread
 
fadymr profile image
F.R Michel

easy , if you use composer , create this class in your project and use it automaticly .
If you not use composer, create this class without namespace and include file class