b0chard Posted 3 hours ago Posted 3 hours ago Hi there! I'm new on using .env file to securely store database credentials on my php project. I watched some tutorials about it, and all of them used a popular third-party package phpdotenv. But, I don't have an idea on installing it on plesk panel. May I request for assistance? Thank youuu!! Quote
wolstech Posted 2 hours ago Posted 2 hours ago It's a library that's meant to be implemented through Composer. If your project doesn't use composer, you'll need to set that up, after which you can just add the package to your composer.json file. When you do a composer install the result is a vendor folder with all the dependencies and a custom-built autoloader script that you call from your code to load them all. Composer is one of those things that's usually best done on your local PC. Once you get everything working, you can commit the composer.json file in your git repo (the vendor folder itself is typically excluded). Plesk has Composer support, so you can use that to process the composer.json and install the required dependencies right on the server. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.