Category : environment-variables

I’m upgrading to Symfony 4.4 from from Symfony 3.4 and the parameters now use .env but terminal commands return the error message In ParameterBag.php line 95: You have requested a non-existent parameter "secret". Did you mean this: "kernel.secret"? the file config/packages/framework.yaml looks like this framework: secret: ‘%env(APP_SECRET)%’ I run ‘composer dump-env dev’ it returns the ..

Read more

I’m using WAMP, with PHP 7.3. To get the environment variables, i’m using the PHP dotenv package. I am getting the following error when I reload the page too often / too fast. The databaseConnector.php <?php namespace AppCommon; class DatabaseConnector{ public static function getConnection(){ $drive = $_ENV[‘DB_DRIVE’]; $host = $_ENV[‘DB_HOST’]; $port = $_ENV[‘DB_PORT’]; $db = ..

Read more