Thank you very much. So simple and clean solution. One more question: ¿is there any way to test this in localhost with web2py development server?
2014-03-13 14:09 GMT-03:00 Dan Feeney <[email protected]>: > You shouldn't need regex for this. Try using the *domains* key instead of > *default_application* in routes.py: > > routers = dict( > BASE = dict( > domains = {'guide.mydomain.com': 'guide', > 'mydomain.com': 'init', > } > ) > ) > > > hth > > > On Wednesday, March 12, 2014 2:19:31 PM UTC-5, Lisandro wrote: >> >> I'm using web2py on production with lighttpd. My site has two web2py >> applications: "init" and "guide". I already created routes.py to hide >> "init" from the url. >> In addition, I would like that "guide" application appears as a >> subdomain, so that every url of this form "mydomain.com/guide/" looks >> like "guide.mydomain.com" >> >> For example, this url >> mydomain.com/guide/posts/index >> should look like >> guide.mydomain.com/posts/index >> >> I don't mind using lighttpd mod_rewrite or web2py routes.py... But I >> don't have **any** experience in regular expresions. So I was wondering if >> someone could give me a hand on this, maybe sharing some examples of >> similar cases. >> >> Thanks in advance! Regards, Lisandro. >> > -- > Resources: > - http://web2py.com > - http://web2py.com/book (Documentation) > - http://github.com/web2py/web2py (Source code) > - https://code.google.com/p/web2py/issues/list (Report Issues) > --- > You received this message because you are subscribed to a topic in the > Google Groups "web2py-users" group. > To unsubscribe from this topic, visit > https://groups.google.com/d/topic/web2py/EhuNoc0TJto/unsubscribe. > To unsubscribe from this group and all its topics, send an email to > [email protected]. > For more options, visit https://groups.google.com/d/optout. > -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.

