1

In the Controller, I would like to use :

return $this->redirectToRoute('bissap_forum_topic', [
        'request' => $request
    ], 307);

But i need to pass some parameters for route bissap_forum_topic

bissap_forum_topic:
    path:     /topic/{topic_id}/{page}
    defaults: { _controller: BISSAPForumBundle:F:topic, page:1 }

Is it possible to rededirect a Route with POST method and some parameters?

Bissap
  • 521
  • 1
  • 5
  • 23
  • Status 307 is not what you are looking for. 307 indicates to the user-agent that the request-method should not be changed. So for example if a you request a page with POST and some-data and the server responds with 307 then the browser will issue the same POST-request with the same Data as before to the redirect-url. (see http://stackoverflow.com/questions/2068418/whats-the-difference-between-a-302-and-a-307-redirect) – gries Sep 28 '15 at 14:02
  • @gries Ok..But, have you got a proposal for my issue? – Bissap Sep 28 '15 at 14:13
  • 1
    You could use something like guzzle to issue a post-request and then redirect with 302 to the resource you would like to display. – gries Sep 28 '15 at 14:15

0 Answers0