OK, I rewrote it with $, and it seems work fine.
But there are one problem

all links must not end with /

for example:
    demo.uk-online.ru/company/info - works fine, but
    http://demo.uk-online.ru/company/info/ - rises invalid request

Have somebody any ideas how to fix it?

This is my routes.py:

routes_in = (
    ('/static/$anything', '/myapp/static/$anything'),
    ('/profile/$anything', '/myapp/profile/$anything'),
    ('/$c/fast_download/$anything', '/myapp/$c/fast_download/
$anything'),
    (r'.*://$sub\.domain\.ru:.* /?', r'/myapp/company/index/$sub'),
    (r'.*://$sub\.domain\.ru:.* /$c/$f/$anything', r'/myapp/$c/$f/$sub/
$anything'),
    (r'.*://$sub\.domain\.ru:.* /$c/$f', r'/myapp/$c/$f/$sub'),
)
routes_out = (
    ('/myapp/static/$anything', '/static/$anything'),
    ('/myapp/profile/$anything', '/profile/$anything'),
    ('/myapp/$c/fast_download/$anything', '/$c/fast_download/
$anything'),
    ('/myapp/company/index/$sub', 'http://$sub.domain.ru'),
    ('/myapp/$c/$f/$sub/$anything', 'http://$sub.domain.ru/$c/$f/
$anything'),
    ('/myapp/$c/$f/$sub', 'http://$sub.domain.ru/$c/$f'),
)

Reply via email to