method public

JsonController::forward()

Класс: \Bitrix\Main\Engine\JsonController

Сигнатура

public forward(Controller|string $controller, string $actionName[, array<string|int, mixed>|null $parameters = null ]) : HttpResponse|mixed

Параметры

$controller Controller|string
$actionName string
$parameters array<string|int, mixed>|null = null

Возвращаемое значение

HttpResponse|mixed

Как применяется в JsonController

JsonController::forward() — метод класса \Bitrix\Main\Engine\JsonController модуля «Главный модуль».

Метод объекта: сначала нужен экземпляр JsonController.

use Bitrix\Main\Engine\JsonController;

/** @var JsonController $object */
$controller = null; // Controller|string
$actionName = '';
$result = $object->forward($controller, $actionName);
// $result: HttpResponse|mixed

Другие методы JsonController

forward() есть и у других классов модуля «Главный модуль»: ComponentController, Controller, DefaultController.

Исходный файл: source/main/lib/engine/jsoncontroller.php:107

Что будем искать? Например,Продвижение