Best practice for relative URIs (was: [Catalyst] Does uri_for() respect https?)

Ashley Pond V apv at sedition.com
Wed Jan 2 22:29:32 GMT 2008


Turns out this is probably being caused by a proxy/SSL-config issue.  
But it leads to another question. What's the best practice for  
relative URIs so that this sort of problem becomes irrelevant?

This seems like the right choice: [% c.uri_for("/my/path").path_query %]

Any say otherwise?

-Ashley

On Dec 31, 2007, at 8:25 PM, Ashley Pond V wrote:

> I'm sorry if this is a stupid question but I'm not in a position to  
> test it myself at the moment.
>
> Does uri_for respect https/http? I have some that are coming up  
> http when the requested resource is https. I know I have a rewrite  
> rule problem too so it might be my own problem. So, this is really  
> just a sanity check.
>
> Given a request to https://mysite.com/myapp
>
>   [% c.uri_for("/whatever") %]
>
>   will produce "https://mysite.com/myapp/whatever"
>        and not "http://mysite.com/myapp/whatever"
>
> Yes?
>
> -Ashley
>



More information about the Catalyst mailing list