Daniel Poelzleithner пишет:
> Amit Upadhyay wrote:
> 
>>Hi,
>>
>>Wish you all a very happy and fruitful new year!
>>
>>Djando URL resolution causes some problem with applications hosted in
>>different subdomains. Consider www.example.com <http://www.example.com>
>>and blog.example.com <http://blog.example.com>. Both of them are running
>>off the same database and share common admin, and so on, but are hosted
>>in different subdomain, which causes problem with URL resolution. To
>>solve this we can copy the settings file and change ROOT_URLCONF to
>>point to different locations. I propose splitting settings.py into
>>common_settings.py and www_settings.py. www_settings.py contains
>>something equivalent to:
>>
> 
> [...]
> 
>>What do you think?
> 
> 
> I think the right approach would be to make the urlresolver in
> handlers.base configurable through a settings variable.
> The default value would be something like
> 
> URL_RESOLVER = "django.core.urlresolvers.RegexURLResolver"
+1

<skip>

> You could do very nice things with this approach, like using a database
> to resolve the url, or even change the other settings depending on the
> hostname you resolve...

I'm already have database-driven URL Resolver. It's built over standard
Django resolver, so anybody can use it with unmodified Django.

Does anybody interesting in it?..

Reply via email to