Thank you anthony for your quick response. I updated *web2py\routes.py* to remain only the following line :
# -*- coding: utf-8 -*- default_application = "myApp" When I open http://127.0.0.1:8000 I am redirected to myApp. So This routes.py file seems to be OK Then, on *web2py\applications\myApp\routes.py* I wrote : routes_in = ( ('/testme', '/myApp/default/index'), ) routes_out = ( ('/myApp/default/index', '/testme'), ) But when I go to http://127.0.0.1:8000/myApp/testme I still have an error invalid controller (testme/index) I have also tested with *web2py\applications\myApp\routes.py* : #!/usr/bin/python # -*- coding: utf-8 -*- routes_in = ( ('/testme', '/default/index'), ) routes_out = ( ('/default/index', '/testme'), ) But I have the same error : invalid controller (testme/index) Le jeudi 2 mai 2013 15:27:50 UTC+2, Anthony a écrit : > > You cannot combine the parameter-based and pattern-based rewrite systems > -- pick one or the other. > > On Thursday, May 2, 2013 8:29:37 AM UTC-4, Loïc wrote: >> >> Hello all, >> >> I want to play with URL revrite. So I took the example in the book ( >> http://web2py.com/books/default/chapter/29/04?search=routes_in#Pattern-based-system >> ) >> >> In the file *web2py\applications\myApp\routes.py* I have : >> #!/usr/bin/python >> # -*- coding: utf-8 -*- >> >> routes_in = ( >> ('/testme', '/myApp/default/index'), >> ) >> routes_out = ( >> ('/myApp/default/index', '/testme'), >> ) >> >> In web2py root dir, I also added a routes.py file containing : >> # -*- coding: utf-8 -*- >> >> routers = dict( >> BASE=dict( >> default_application='myApp', >> ), >> ) >> >> >> I restarted web2py to reload routes, but when I go on >> http://127.0.0.1:8000/testme or on http://127.0.0.1:8000/myApp/testme I >> have an error : >> invalid function (default/testme) >> >> >> Can somebody explain me what is wrong is my routes.py files? >> >> Thank you >> >> -- --- 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 web2py+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.