We are developing a few Django projects. The development versions are accessible in the local network under some directories of the local server's IP (i.e. http://1.2.3.4/example/) and the published versions are accessible under some domains directly (i.e. http://example.com/).
If you have a similar situation, how are you dealing with the URLs of FlatPages? The problem is that in the development version the URLs are like /example/about/ and in the published version they are like /about/. So we need to modify all the flatpages when transfer the data from the development version to the public one. The ideas that came to my mind: 1. creating my own FlatPage model based on the contributed one which corresponds to the directory setting in the project settings. 2. installing a BIND (DNS) server locally so that we didn't have to put projects under specific directories, but rather under local domain names (i.e. http://example.local/). 3. creating some middleware that removes directory name from the requested URL before URL parsing. What are the best practices for doing that? What do you do in similar situations? Regards, Aidas Bendoraitis [aka Archatas] --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---