Browse Source

Russian translation, guide enhancements [skip ci]

tags/3.0.0-alpha1
Alexaksandr 9 years ago committed by Alexander Makarov
parent
commit
58b55a5632
  1. 22
      docs/guide-ru/runtime-overview.md
  2. 2
      docs/guide-ru/structure-extensions.md
  3. 2
      docs/guide-ru/structure-views.md
  4. 6
      docs/guide/runtime-overview.md
  5. 2
      docs/guide/structure-views.md

22
docs/guide-ru/runtime-overview.md

@ -0,0 +1,22 @@
Обзор
========
Все запросы, обрабатываемые Yii приложением, проходят подобный путь.
1. Пользователь создает запрос ко [входному скрипту](structure-entry-scripts.md) `web/index.php`.
2. Входной скрипт загружает [конфигурацию](concept-configurations.md) и создает экземпляр [приложения](structure-applications.md) для обработки запроса.
3. Приложение определяет запрошенный [маршрут](runtime-routing.md) при помощи компонента [request](runtime-requests.md).
4. Приложение создает экземпляр [контроллера](structure-controllers.md) для обработки запроса.
5. Контроллер создает экземпляр [действия](structure-controllers.md) и выполняет фильтры для этого действия.
6. При неудачном выполнении любого [фильтра](structure-filters.md), действие не выполняется.
7. При успешном выполнении всех фильтров, выполняется действие.
8. Действие загружает [модель](structure-models.md) данных, возможно, из базы данных.
9. Действие рендерит [представление](structure-views.md) и передает ему модель данных.
10. Результат рендеринга передается в компонент приложения [response](runtime-responses.md).
11. Компонент response посылает готовые данные пользователю.
Ниже представлена диаграмма обработки запроса приложением.
![Request Lifecycle](images/request-lifecycle.png)
В данном разделе описаны подробности некоторых этапов обработки запроса.

2
docs/guide-ru/structure-extensions.md

@ -2,7 +2,7 @@
========== ==========
Расширения - это распространяемые программные пакеты, специально разработанные для использования в приложениях Yii и Расширения - это распространяемые программные пакеты, специально разработанные для использования в приложениях Yii и
содержащие готовые функции. Например, расширение [yiisoft/yii2-debug](tool-debugger.md) добавляет удобную отладочную содержащие готовые функции. Например, расширение [yiisoft/yii2-debug](https://github.com/yiisoft/yii2-debug) добавляет удобную отладочную
панель в нижнюю часть каждой страницы вашего приложения, чтобы помочь вам разобраться в том, как генерируются панель в нижнюю часть каждой страницы вашего приложения, чтобы помочь вам разобраться в том, как генерируются
страницы. Вы можете использовать расширения для ускорения процесса разработки. Вы также можете оформить ваш код как страницы. Вы можете использовать расширения для ускорения процесса разработки. Вы также можете оформить ваш код как
расширение, чтобы поделиться с другими людьми результатами вашей работы. расширение, чтобы поделиться с другими людьми результатами вашей работы.

2
docs/guide-ru/structure-views.md

@ -523,7 +523,7 @@ $this->registerMetaTag(['name' => 'keywords', 'content' => 'yii, framework, php'
параметра при вызове метода. параметра при вызове метода.
К примеру, следующий код регистрирует два мета тэга "description", однако отрендерен будет только второй. К примеру, следующий код регистрирует два мета тэга "description", однако отрендерен будет только второй.
```html ```php
$this->registerMetaTag(['name' => 'description', 'content' => 'Мой сайт сделан с помощью Yii!'], 'description'); $this->registerMetaTag(['name' => 'description', 'content' => 'Мой сайт сделан с помощью Yii!'], 'description');
$this->registerMetaTag(['name' => 'description', 'content' => 'Это сайт о забавных енотах.'], 'description'); $this->registerMetaTag(['name' => 'description', 'content' => 'Это сайт о забавных енотах.'], 'description');
``` ```

6
docs/guide/runtime-overview.md

@ -10,10 +10,10 @@ Each time when a Yii application handles a request, it undergoes a similar workf
the [request](runtime-requests.md) application component. the [request](runtime-requests.md) application component.
4. The application creates a [controller](structure-controllers.md) instance to handle the request. 4. The application creates a [controller](structure-controllers.md) instance to handle the request.
5. The controller creates an [action](structure-controllers.md) instance and performs the filters for the action. 5. The controller creates an [action](structure-controllers.md) instance and performs the filters for the action.
6. If any filter fails, the action is cancelled. 6. If any [filter](structure-filters.md) fails, the action is cancelled.
7. If all filters pass, the action is executed. 7. If all filters pass, the action is executed.
8. The action loads a data model, possibly from a database. 8. The action loads a data [model](structure-models.md), possibly from a database.
9. The action renders a view, providing it with the data model. 9. The action renders a [view](structure-views.md), providing it with the data model.
10. The rendered result is returned to the [response](runtime-responses.md) application component. 10. The rendered result is returned to the [response](runtime-responses.md) application component.
11. The response component sends the rendered result to the user's browser. 11. The response component sends the rendered result to the user's browser.

2
docs/guide/structure-views.md

@ -599,7 +599,7 @@ regardless whether the meta tags are the same or not.
To make sure there is only a single instance of a meta tag type, you can specify a key as a second parameter when calling the method. To make sure there is only a single instance of a meta tag type, you can specify a key as a second parameter when calling the method.
For example, the following code registers two "description" meta tags. However, only the second one will be rendered. For example, the following code registers two "description" meta tags. However, only the second one will be rendered.
```html ```php
$this->registerMetaTag(['name' => 'description', 'content' => 'This is my cool website made with Yii!'], 'description'); $this->registerMetaTag(['name' => 'description', 'content' => 'This is my cool website made with Yii!'], 'description');
$this->registerMetaTag(['name' => 'description', 'content' => 'This website is about funny raccoons.'], 'description'); $this->registerMetaTag(['name' => 'description', 'content' => 'This website is about funny raccoons.'], 'description');
``` ```

Loading…
Cancel
Save