MediaWiki master
|
This is an exception class that extends HttpException and will generate a redirect when handled. More...
Inherits MediaWiki\Rest\HttpException.
Public Member Functions | |
__construct (int $code, string $target) | |
getTarget () | |
![]() | |
__construct ( $message, $code=500, $errorData=[]) | |
getErrorData () | |
This is an exception class that extends HttpException and will generate a redirect when handled.
It is used when a redirect is treated as an exception output in your API, and you want to be able to throw it from wherever you are and immediately halt request processing.
Definition at line 15 of file RedirectException.php.
MediaWiki\Rest\RedirectException::__construct | ( | int | $code, |
string | $target ) |
int | $code | The HTTP status code (3xx) for this redirect |
string | $target | The redirect target (an absolute URL) |
Definition at line 29 of file RedirectException.php.
MediaWiki\Rest\RedirectException::getTarget | ( | ) |
Definition at line 34 of file RedirectException.php.