src/Controller/Output.php
public function redirect($url, $code = 303)
    {
        $this->respondWith($code);
        $this->setResponseHeader('Location', $url);
        
        $urlHtml = htmlentities($url);
        $this->output('You are being redirected to <a href="' . $urlHtml . '">' . $urlHtml . '</a>', 'text/html');
    }
public function redirect($url, $code = 303)
    {
        $this->respondWith($code);
        $this->setResponseHeader('Location', $url);
        
        $urlHtml = htmlentities($url);
        $this->output('You are being redirected to <a href="' . $urlHtml . '">' . $urlHtml . '</a>', 'text/html');
    }
public function redirect ( $ url , $ code = 303 ) { $ this -> respondWith ( $ code ) ; $ this -> setResponseHeader ( 'Location' , $ url ) ; $ urlHtml = htmlentities ( $ url ) ; $ this -> output ( 'You are being redirected to <a href="' . $ urlHtml . '">' . $ urlHtml . '</a>' , 'text/html' ) ; }
Redirect to url and output a short message with the link

@param string $url
@param int    $code  301 (Moved Permanently), 302 (Found), 303 (See Other) or 307 (Temporary Redirect)
Redirect to url and output a short message with the link