Reputation: 197
How Can I set my Symfony 2 project to use parameters.yml instead of parameters.ini?
in a controller, I can get variables from parameters.ini like this:
$this->container->getParameter('param_name');
Upvotes: 2
Views: 1625
Reputation: 36191
In your app/config/config.yml replace:
imports:
- { resource: parameters.ini }
with:
imports:
- { resource: parameters.yml }
Upvotes: 6