This method prepends the URL created by UrlManager::createUrl with the [[hostInfo]].
Note that unlike [[\yii\helpers\Url::toRoute()]], this method always treats the given route
as an absolute route.
public createAbsoluteUrl ( string | array $params, string | null $scheme = null ) : string | ||
$params | string | array | use a string to represent a route (e.g. `site/index`), or an array to represent a route with query parameters (e.g. `['site/index', 'param1' => 'value1']`). |
$scheme | string | null | the scheme to use for the URL (either `http`, `https` or empty string for protocol-relative URL). If not specified the scheme of the current request will be used. |
return | string | the created URL |