Solar_Http_Response::redirect()

public void Solar_Http_Response::redirect ( Solar_Uri_Action|string $spec , int|string $code = '302' )

Issues an immediate "Location" redirect.

Parameters

  • (Solar_Uri_Action|string) $spec: The URI to redirect to.

  • (int|string) $code: The HTTP status code to redirect with; default is '302 Found'.

Returns

  • (void)

Description

Issues an immediate "Location" redirect.

Use instead of display() to perform a redirect. You should die() or exit() after calling this.



Local