On Sat, 2008-10-04 at 09:42 -0700, John Allen wrote: [...] > This works fine but I am wondering: can the function in > ABSOLUTE_URL_OVERRIDES make use of reverse(), so as to avoid hard- > coding the "/cms" into the setting?
No, you can't do this. The rule is that you cannot use any pieces of Django itself in your settings file (and ABSOLUTE_URL_OVERRIDES is a setting). This is because Django relies on using your settings, so there's almost always a chicken-and-egg sort of problem. In this case, reverse() depends on knowing about your URL configuration. But that is specified by the ROOT_URLCONF setting (and possibly some other settings), so reverse() requires the settings to be fully loaded, leading to an obvious catch-22. Regards, Malcolm --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---