src/Silex/Application/ToolsTrait.php
public function redirectToRoute($route, array $parameters = [], $status = 302)
    {
        return new RedirectResponse($this['url_generator']->generate($route, $parameters), $status);
    }
public function redirectToRoute($route, array $parameters = [], $status = 302)
    {
        return new RedirectResponse($this['url_generator']->generate($route, $parameters), $status);
    }
public function redirectToRoute ( $ route , array $ parameters = [ ] , $ status = 302 ) { return new RedirectResponse ( $ this [ 'url_generator' ] -> generate ( $ route , $ parameters ) , $ status ) ; }
Redirects the user to route with the given parameters.

@param string $route      The name of the route
@param mixed  $parameters An array of parameters
@param int    $status     The status code (302 by default)

@return RedirectResponse
Redirects the user to route with the given parameters .