On Thu, Apr 16, 2009 at 7:05 AM, Jonathan Gardner <[email protected]> wrote: > > On Apr 16, 6:12 am, Damian <[email protected]> wrote: >> How about: >> >> in your ini file: >> https_server = abc:123 >> >> and in mako (or templating engine etc): >> <%from pylons import config %> >> ${h.url("/search", host=config['https_server'])} >> > > You'd have to specify protocol='https' as well, right? > >> Guess it might be useful to have a default/standard way of specifying >> where your https lives in the ini file, it's something I imagine gets >> used a lot (I certainly use it often). > > Yes, that would be a nice feature. I guess a lot of people don't run > servers that serve both HTTP and HTTPS traffic behind a proxy, though. > I find it invaluable myself.
It's more fundamental than that. Most people do not run hybrid HTTP/HTTPS sites with distributed responsibilities, and for those that do, there's no standard for how the framework or Routes should handle the linkage to the "other" site. So it treats it as a completely external site. In most HTTP/HTTPS situations, the HTTP site is either a simple redirect to the HTTPS site, or serves the same content indifferently (so it's the same application). Perhaps something could be added to Routes or url(), but i don't know what. And until we articulate clearly what it is, it's not worth putting a half-baked solution in. -- Mike Orr <[email protected]> --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "pylons-discuss" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/pylons-discuss?hl=en -~----------~----~----~----~------~----~------~--~---
