Skip to content
PHP Ecosystem
Explore

UrlNormalizerRedirectException

API reference › yii › web › UrlNormalizerRedirectException

classyii\web\UrlNormalizerRedirectException
Extendsyii\base\Exception » Exception
Since2.0.10
Sourceframework/web/UrlNormalizerRedirectException.php

UrlNormalizerRedirectException represents an information for redirection which should be performed during the URL normalization.

PropertyTypeDescriptionDefined by
$schemebool|stringThe URI scheme to use in the generated URL for redirection Default: null.UrlNormalizerRedirectException
$statusCodeintThe HTTP status code Default: null.UrlNormalizerRedirectException
$urlarray|stringThe parameter to be used to generate a valid URL for redirection Default: null.UrlNormalizerRedirectException
MethodDescriptionDefined by
__construct()UrlNormalizerRedirectException
getName()yii\base\Exception
public function __construct(array|string $url, int $statusCode = 302, bool|string $scheme = false, string|null $message = null, int $code = 0, Throwable|null $previous = null)

Parameters

ParameterTypeDescription
$urlarray|stringThe parameter to be used to generate a valid URL for redirection. This will be used as first parameter for Url::to()
$statusCodeintHTTP status code used for redirection
$schemebool|stringThe URI scheme to use in the generated URL for redirection. This will be used as second parameter for Url::to()
$messagestring|nullThe error message
$codeintThe error code
$previousThrowable|nullThe previous exception used for the exception chaining