library/Garp/Controller/Helper/CanonicalUrl.php
public function redirect($canonical) {
        if (!preg_match('~^[a-z]+://~', $canonical)) {
            $canonical = new Garp_Util_FullUrl($canonical);
        }
        $controller = $this->getActionController();
        $controller->getHelper('cache')->disable();
        $controller->getHelper('viewRenderer')->setNoRender(true);
        $controller->getHelper('layout')->disableLayout();
        $controller->getHelper('redirector')->gotoUrl((string)$canonical, array('code' => 301));
    }
public function redirect($canonical) {
        if (!preg_match('~^[a-z]+://~', $canonical)) {
            $canonical = new Garp_Util_FullUrl($canonical);
        }
        $controller = $this->getActionController();
        $controller->getHelper('cache')->disable();
        $controller->getHelper('viewRenderer')->setNoRender(true);
        $controller->getHelper('layout')->disableLayout();
        $controller->getHelper('redirector')->gotoUrl((string)$canonical, array('code' => 301));
    }
public function redirect ( $ canonical ) { if ( ! preg_match ( '~^[a-z]+://~' , $ canonical ) ) { $ canonical = new Garp_Util_FullUrl ( $ canonical ) ; } $ controller = $ this -> getActionController ( ) ; $ controller -> getHelper ( 'cache' ) -> disable ( ) ; $ controller -> getHelper ( 'viewRenderer' ) -> setNoRender ( true ) ; $ controller -> getHelper ( 'layout' ) -> disableLayout ( ) ; $ controller -> getHelper ( 'redirector' ) -> gotoUrl ( ( string ) $ canonical , array ( 'code' => 301 ) ) ; }
Redirect to the canonical URL
@param String $canonical
@return Void
Redirect to the canonical URL