Re: Router redirect pass all parameters to another domian
From the documentation, I'm not convinced that is can be used to append the content of the original URL to the new destination.
-- http://book.cakephp.org/2.0/en/development/routing.html#redirect-routing
However, you may be better off implementing a site wide redirect like that, in your web server, rather than a CakePHP application. It will perform much better.
On Tuesday, 21 January 2014 07:49:09 UTC+10, gonzela2006 wrote:
On Tuesday, 21 January 2014 07:49:09 UTC+10, gonzela2006 wrote:
Hello,I want to use Router::redirect to redirect to another domain and pass all parameters to this domainExample:Redirect this urlhttp://domain-one.com/posts/view/1 toI tried the followingRouter::redirect( '/*', 'http://domain-two.com/', array('persist' => true) );but it redirect to http://domain-two.com/ without parameters.Please adviseThanks
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP
---
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cake-php+unsubscribe@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/groups/opt_out.
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home