On Sun, Mar 28, 2010 at 6:45 AM, SgtUnix <[email protected]> wrote: > I've got static pages (public/index.html, and so on) that I wish to > serve on www.mydomain.com and mydomain.com. > > However, all other subdomains (i.e. *.mydomain.com) must be sent to a > controller. > > How do I achieve this with Pylons and Routes? I've played around for > a few hours now but I just can't seem to make it work. > > Any ideas would be appreciated.
You could try making a first route with a function condition. So the path matches all URLs, the function checks what the requested domain is, and either sets the controller if it's a wildcard subdomain, or returns false if it's one of the two domains. http://routes.groovie.org/setting_up.html#conditions -- 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.
