https redirect

From the controller, to make a redirect i would : php $this->response->redirect('login/index'); If i am on HTTP, redirect will stay on HTTP.

Is there an easy way to redirect to a HTTPS link , without having to provide the hostname ? ( we have devel-host ,staging,live )

I don't think there is. If you're redirecting to https from http, I believe you need the whole URL. However, that doesn't need to be hardcoded - you can pull that from $_SERVER



16.6k

@alexconrad Hi! Did you solved your problem? Could you tell how? I mean, what the best practice is? :)



16.6k

@alexconrad Could you look at my post here and evaluate my solution? Could you provide the one you have choosen? ;> Thanks!

A link: http://forum.phalconphp.com/discussion/2655/force-https-#C13522