How to get Django url correctly?

Posted by Satoru.Logic on Stack Overflow See other posts from Stack Overflow or by Satoru.Logic
Published on 2010-04-29T01:02:03Z Indexed on 2010/04/29 1:07 UTC
Read the original article Hit count: 206

Filed under:
|

Hi, all.

I have set up a url mapping that goes like this:

(r'enroll/$', 'enroll')

In my development environment this mapping is used when I visit '/enroll/'.

But in the production environment, the Django application is under '/activity/' and '/activity/enroll/' should be used.

Please tell me how do I get the correct url in both cases.

Thanks in advance.

© Stack Overflow or respective owner

Related posts about django

Related posts about url-routing