Look at router.example.py in the /web2py root folder. I think this should 
do it:

routers = dict(
    BASE = dict(
        default_controller = 'default',
        default_function = 'index'
    )
)

Goes in routes.py, which goes in the /web2py root folder.

Anthony

On Monday, November 28, 2011 9:27:04 AM UTC-5, lyn2py wrote:
>
> I would like to add that other than index function, I wish to map
> >> localhost/app/default/any_function
> to
> >> localhost/app/any_function
>
> Thank you!
>
>
> On Nov 28, 5:47 pm, lyn2py <lyn...@gmail.com> wrote:
> > I know routes.py has been brought up many times, but I haven't been
> > able to get it to work for me.
> >
> > Here's what I want to do:
> > I would like to remove "default" from the URL in>> 
> localhost/app/default/index
> >
> > so that it appears as
> >
> > >> localhost/app/index
> >
> > I have referenced the posts in google groups and athttp://
> web2py.com/book/default/chapter/04#URL-Rewrite
> >
> > I have reloaded routes in the admin before testing.
> >
> > Where should I put routes.py and what code should I put inside it to
> > make this work?
> >
> > Thanks!
>
>

Reply via email to