Hi, On 31.03.2009, at 21:54, Ross wrote:
> > Thanks for your reply, and you anticipated my follow up question. A > brief look found how to read an enviro var from python: > > os.environ['USER'] give me $USER from the OS it appears (haven't > tried it yet). > > BUT, I also took a close look at the request.META data, wondering if > there isn't something in there. Sure enough, I found the strangely > named META variable "_" (underscore) which exists when the request is > handled by the dev server, whose value is "manage.py" > > When the same thing is requested through mod_python + apache2, I see > that META['_'] doesn't exist. So I could test for the existence of > underscore in the meta tags I guess. But perhaps using an enviro > variable is a more elegant approach. > > Thx for the info... > Do you really need to determine between devserver and mod_python or do you actually want to determine between dev and production server? If it's just dev and production server why not use settings.DEBUG? adi --~--~---------~--~----~------------~-------~--~----~ 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 django-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---