Zend, Global variable in Application.ini?

后端 未结 6 1250
失恋的感觉
失恋的感觉 2021-02-04 14:24

I have a question as I need to have a global static variable and I have question is any possibility to add it to the application.ini file, how to do it?

Or I have to:

6条回答
  •  梦谈多话
    2021-02-04 15:13

    The best solution for me was to create a variable in index.php file. I have added: defined('VARIABLE_NAME') || define('VARIABLE_NAME', 'Something here');

    And now I can access to it from everywhere ;D Thanks a lot!

提交回复
热议问题