The syntax suggested looks a bit different from the examples given in 2 and 3 below. When the IP address is omitted, does it default to any IPs (i.e., catch all)? E.g., Is ('/admin/(?P<a>.*)','/admin/\g<a>') the same as ('^.*:/admin/(?P<a>.*)','/admin/\g<a>') ?
By the way, could someone teach me what the key <a> does? 1. http://mdp.cti.depaul.edu/AlterEgo/default/show/101 from Django to web2py (note: in urls.py vs routes.py, should "routes_out=(" be "routes_in= ("?) 2. http://www.web2py.com/AlterEgo/default/show/67 url rewrite and routes 3. http://www.web2py.com/AlterEgo/default/show/42 routes in web2py and url rewrite Thanks, and cheers, Teru On 4月9日, 午前8:34, mdipierro <mdipie...@cs.depaul.edu> wrote: > in order to the remapping you must know which apps you have. > Say you have admin, welcome, yourapp. You can do > > routes_in= ( > ('/admin/(?P<a>.*)','/admin/\g<a>'), > ('/welcome/(?P<a>.*)','/welcome/\g<a>'), > ('/(?P<a>.*)','/yourapp/\g<a>'), > ) > > routes_out=(('/yourapp/(?P<a>.*)','/\g<a>'),) > > On Apr 8, 3:47 pm, bsnipes <snipes.br...@gmail.com> wrote: > > > > > On Apr 8, 3:10 pm, Boris Manojlovic <boris.manojlo...@gmail.com> > > wrote: > > > > I do not know if you are aware that if you call your application init > > > you will get exactly that what you want. > > > Hmm.. just tried it and while it does make that app come up when just > > the base url is used in the browser ( testing with the standard web2py > > without apache and using port 8000 ) it doesn't map the static items > > or the functions in the default controller to the base url. For > > instance: > > > images show up as:http://localhost:8000/init/static/image.jpgand > > nothttp://localhost:8000/static/image.jpg > > functions in the init/default.py controller cannot be accessed as > > from the base url - for instance a def read() in default.py can't be > > accessed ashttp://localhost:8000/read/1 > > > Brian --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "web2py Web Framework" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~----------~----~----~----~------~----~------~--~---