search

Home  >  Q&A  >  body text

How to define business constants in laravel

When I used Thinkphp in the past, there was a config file that could define some business-level constants. For example, order_open => 1, order_close=>0. Currently, when using laravel, we only know that some system-level constants can be saved in .env files. Which directory is more appropriate to save business-level constants in.

仅有的幸福仅有的幸福2792 days ago645

reply all(3)I'll reply

  • 大家讲道理

    大家讲道理2017-05-16 13:03:15

    config directory. In it, you can create corresponding configuration files according to the business type

    reply
    0
  • ringa_lee

    ringa_lee2017-05-16 13:03:15

    Also config.

    reply
    0
  • phpcn_u1582

    phpcn_u15822017-05-16 13:03:15

    Configuration files can be stored in the config directory.

    reply
    0
  • Cancelreply