Tom, thanks for your feedback.
I guess what I was asking was how to get the domain/subdomain info from places
like models and settings -- i.e. places that have no connection to a request.
Still, I see a way through and will employ your suggestions.
\d
--~--~-~--~~~
Settings can be altered at runtime - the middleware code I referenced
does this - but the Django docs warn against it:
http://docs.djangoproject.com/en/dev/topics/settings/#altering-settings-at-runtime
I'd recommend using middleware to set the subdomain in the request
scope, e.g.:
http://www.dj
On Tuesday, 13 January 2009 19:28:01 Tom Dyson wrote:
> We do something like this with middleware in the Carbon Account[1]:
I have not used middleware yet, so will look into it. I am not sure if it can
supply request.META *within* settings.py though.
I want to set certain variables depending on
We do something like this with middleware in the Carbon Account[1]:
http://code.thecarbonaccount.com/trac/browser/trunk/calculator/middleware/autobrand.py
Hope this helps
Tom
[1] http://www.thecarbonaccount.com
On Jan 13, 3:10 pm, Donn wrote:
> Hi,
> Can anyone help me get some extra info in
Hi,
Can anyone help me get some extra info in settings.py?
I have a domain that I want to point to various different Django apps
depending on the 'hostname' portion of the domain name.
***.mydomain.com has (for ***):
www
comics
stuff
I want that first portion (www, comics, stuff) available in
5 matches
Mail list logo