[web2py] url rewriting

2011-04-03 Thread Shark
Hello I am asking about url rewriting in web2py withGAE I want to make our site page www.site.com/init/login to www.site,com/login can you help me ? someone tell me change app,yaml others say change routers.py so I need your help Thanks

Re: [web2py] url rewriting

2011-04-03 Thread Jonathan Lundell
On Apr 3, 2011, at 9:01 AM, Shark wrote: > > Hello > > I am asking about url rewriting in web2py withGAE > > I want to make our site page > www.site.com/init/login > > to > > www.site,com/login > > can you help me ? > > someone tell me change app,yaml > others > say change routers.py Change

Re: [web2py] url rewriting

2011-04-03 Thread Ahmed Sharkawy
*I want url rewriting not changing the default route * On 3 April 2011 18:40, Jonathan Lundell wrote: > On Apr 3, 2011, at 9:01 AM, Shark wrote: > > > > Hello > > > > I am asking about url rewriting in web2py withGAE > > > > I want to make our site page > > www.site.com/init/login > > > > to > >

Re: [web2py] url rewriting

2011-04-03 Thread pbreit
Setting the default_application works really well. Would actual re-writing need to be performed by the server?

Re: [web2py] url rewriting

2011-04-03 Thread Jonathan Lundell
On Apr 3, 2011, at 2:11 PM, pbreit wrote: > Setting the default_application works really well. Would actual re-writing > need to be performed by the server? That will interpret / as /init/default/index, but it won't help for /login

Re: [web2py] url rewriting

2011-04-03 Thread pbreit
Oh right, cuz login is going to be /user/login ?

Re: [web2py] url rewriting

2011-04-03 Thread Jonathan Lundell
On Apr 3, 2011, at 2:22 PM, pbreit wrote: > > Oh right, cuz login is going to be /user/login ? Well, that too, but simply setting default_application (without any routing) will never suppress the application unless it's also suppressing the controller and function.

Re: [web2py] url rewriting

2011-04-04 Thread Ahmed Sharkawy
*I use GAE and I use the app.yaml to solve this but there is anther problem I have more than one function in the file so I want to point to the specific function the code in app.yaml is - url: /login script: applications\init\controllers\login.py but if I have a script contain 2 functions how t

Re: [web2py] url rewriting

2011-04-04 Thread Jonathan Lundell
On Apr 4, 2011, at 5:02 AM, Ahmed Sharkawy wrote: > I use GAE and I use the app.yaml to solve this > but there is anther problem > I have more than one function in the file so I want to point to the specific > function > > the code in app.yaml is > - url: /login > script: applications\init\cont

Re: [web2py] url rewriting

2011-04-04 Thread Bruno Rocha
I dont if it helps, but I use the autoroutes which works very fine for me: http://snipt.net/rochacbruno/routesconf http://snipt.net/rochacbruno/routespy -- Bruno Rocha [ About me: http://zerp.ly/rochacbruno ] On Sun, Apr 3, 2011 at 1:01 PM, Shark wrote: > Hello > > I am asking about url re

Re: [web2py] url rewriting

2011-04-04 Thread Ahmed Sharkawy
*@*Bruno Rocha * t is very good site but the answer is so complicated !* On 4 April 2011 22:13, Bruno Rocha wrote: > I dont if it helps, but I use the autoroutes which works very fine for me: > > http://snipt.net/rochacbruno/routesconf > > http://snipt.net/rochacbruno/routespy > > > -- > Bruno

Re: [web2py] url rewriting

2011-04-04 Thread Bruno Rocha
at the web2py root folde I just created a file called routes.conf with this http://snipt.net/rochacbruno/routesconf (replace my domain with your domain and application) at the web2py root folder create a file calles routes.py with: http://snipt.net/rochacbruno/routespy Restart web2py and www.

Re: [web2py] url rewriting

2011-04-04 Thread Ahmed Sharkawy
*thanks for your answer but I want to change many urls so I think your script can do so ?! I want init/account/get to be init/account init/login/index to be init/login * On 4 April 2011 23:20, Bruno Rocha wrote: > at the web2py root folde I just created a file called routes.conf with this > > ht

Re: [web2py] url rewriting

2011-04-04 Thread Jonathan Lundell
On Apr 4, 2011, at 2:50 PM, Ahmed Sharkawy wrote: > thanks for your answer but I want to change many urls so I think your script > can do so ?! > > I want init/account/get to be init/account > init/login/index to be init/login You'll find it easier if you make the default function in each contro

Re: [web2py] url rewriting

2011-04-04 Thread Ahmed Sharkawy
Thanks Jonathan Lundell for this advice *thanks for your help all but the problem was that I should restart the web2py framework not only stop server ! I don't know why ! Thanks guys for your help I finished the task :D but I want to ask about the reguler expression which some people use , c

[web2py] URL Rewriting for an application

2011-12-20 Thread Abhishek Gupta
I am using script/autoroutes.py for the application with following changes : config = ''' server.com /app/default ''' def auto_in ... routes += [('^.*:/(?P[^\\/\.]+)(?P.*)$', '/profile/\g\g')] return routes def auto_out... ... routes += [('^.*:/profile/(?P[^\\/\.]+)(

[web2py] url rewriting and url mapping

2014-09-17 Thread olivier hubert
My application is a clone of Reddit clone app from Massimo. This is the url I use to show all the posts in a category. http://127.0.0.1:8000/list_posts_by_votes/16 16 = category id I would like this url in place of. http://127.0.0.1:8000/my_category_name It's the same to show a post http://127.0.