How to create a custom yaml config file in Symfony

前端 未结 6 495
面向向阳花
面向向阳花 2021-02-02 13:52

What I want to do is quite simple: store data in a custom config file that I want to read later on.

I created my file something.yml that I put in the global

6条回答
  •  佛祖请我去吃肉
    2021-02-02 13:57

    Do not modify the index.php this is dirty!

    Juste add this line to your app/frontend/config/frontendConfiguration.class.php

    require_once($this->getConfigCache()->checkConfig('config/something.yml'));
    

    (adapt with your own app name)

提交回复
热议问题