Back to the Routes

I had some doubts if the Routes URL mapper would work in my hosting environment, but it does. And it does its job very good and helps me getting away from mod_rewrite.

Also, while examining the source, I discovered a bug with URL prefixes and sent a patch to Ben Bangert that helped him to work around the problem.

Update: For the time being, I use the following mod_rewrite rules to hand every request except for my static files over to the Python script which passes the REQUEST_URI environment variable to the Routes mapper.

Apache configuration:

RewriteRule ^robots.txt$        robots.txt      [PT,L]
RewriteRule ^(images/.*)$       $1              [PT,L]
RewriteRule ^(style/.*)$        $1              [PT,L]
RewriteRule ^.*$                [PT,L,QSA]

result = m.match(os.environ['REQUEST_URI'])

Update: Ben has released Routes 1.3.1.