Skip to content

Commit

Permalink
dev
Browse files Browse the repository at this point in the history
  • Loading branch information
skeeks-semenov committed May 4, 2018
1 parent 105ee57 commit ac63d72
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions docs/structure.rst
Original file line number Diff line number Diff line change
Expand Up @@ -238,13 +238,15 @@ Directories
Варианты определения константы ENV
----------------------------------

Определение через .htaccess
Определение через .htaccess ``/frontend/web/index.php``:


.. code-block:: bash
SetEnv ENV dev
``/frontend/web/index.php``:

.. code-block:: php
$env = getenv('ENV');
Expand All @@ -256,7 +258,7 @@ Directories
require(ROOT_DIR . '/vendor/skeeks/cms/app-web.php');
Определение окружения для определенного ip адреса
Определение окружения для определенного ip адреса ``/frontend/web/index.php``:

.. code-block:: php
Expand All @@ -268,3 +270,6 @@ Directories
define("ROOT_DIR", dirname(dirname(__DIR__)));
require(ROOT_DIR . '/vendor/skeeks/cms/app-web.php');
Таким образом любой разработчик имеет возможность иметь собственную конфигурацию, а проект единую кодовую базу.
Так же любое установленное расширение, которое предоставляет конфигурацию по текущим правилам, сразу приносит настройку в проект.

0 comments on commit ac63d72

Please sign in to comment.