bixuehujin/blink

Examples

rspadim opened this issue · 1 comments

Hi guys, could be possible some examples about how to access "server" configuration

For example, at directory structure we have /src/config/server.php. How using HttpController access this configuration? for example I want to set some HTTP configurations at server.php and read it at application

The configuration in /src/config/server.php is only used for configuring Servers for now, such as SwServer, CgiServer, which can not be accessed out of the Server object.

If you want to set custom configurations, you may have the following two ways:

  1. Using Environment Configuration which described at https://docs.rethinkphp.com/blink-framework/v0.4/en/5-1-env-file.html
  2. Introduce a config component to manage your config at one place