Re: finding domain name

2008-09-24 Thread Lawrence D'Oliveiro
In message <[EMAIL PROTECTED]>, Bobby Roberts wrote: > evidently the environ dictionary is off limits on our server. Why? > It can't > be that tough in python to get the current complete url being viewed. > It's a snap in asp(which is my background). Unless, of course, the relevant information

Re: finding domain name

2008-09-24 Thread Bruno Desthuilliers
Bobby Roberts a écrit : On Sep 23, 1:23 pm, Bruno Desthuilliers <[EMAIL PROTECTED]> wrote: Bobby Roberts a écrit : hi group. I'm new to python and need some help and hope you can answer this question. I have a situation in my code where i need to create a file on the server and write to it.

Re: finding domain name

2008-09-23 Thread Gabriel Genellina
En Tue, 23 Sep 2008 09:37:44 -0300, Bobby Roberts <[EMAIL PROTECTED]> escribió: hi group. I'm new to python and need some help and hope you can answer this question. I have a situation in my code where i need to create a file on the server and write to it. That's not a problem if i hard cod

Re: finding domain name

2008-09-23 Thread Bobby Roberts
On Sep 23, 1:23 pm, Bruno Desthuilliers <[EMAIL PROTECTED]> wrote: > Bobby Roberts a écrit : > > > hi group.  I'm new to python and need some help and hope you can > > answer this question.  I have a situation in my code where i need to > > create a file on the server and write to it.  That's not a

Re: finding domain name

2008-09-23 Thread Bruno Desthuilliers
Bobby Roberts a écrit : hi group. I'm new to python and need some help and hope you can answer this question. I have a situation in my code where i need to create a file on the server and write to it. That's not a problem if i hard code the path. However, the domain name needs to be dynamic s

Re: finding domain name

2008-09-23 Thread Tino Wildenhain
Hi, Bobby Roberts wrote: On Sep 23, 9:10 am, Tino Wildenhain <[EMAIL PROTECTED]> wrote: Bobby Roberts wrote: Depends on the technology/web framework. If you use WSGI, you should use something like: host_name = environ.get("HTTP_HOST", None) or environ["SERVER_NAME"] -- Gerhard Yeah i already

Re: finding domain name

2008-09-23 Thread Bruno Desthuilliers
Bobby Roberts a écrit : On Sep 23, 9:10 am, Tino Wildenhain <[EMAIL PROTECTED]> wrote: Bobby Roberts wrote: Depends on the technology/web framework. If you use WSGI, you should use something like: host_name = environ.get("HTTP_HOST", None) or environ["SERVER_NAME"] -- Gerhard Yeah i already tr

Re: finding domain name

2008-09-23 Thread Bobby Roberts
On Sep 23, 9:10 am, Tino Wildenhain <[EMAIL PROTECTED]> wrote: > Bobby Roberts wrote: > >> Depends on the technology/web framework. If you use WSGI, you should use > >> something like: > > >> host_name = environ.get("HTTP_HOST", None) or environ["SERVER_NAME"] > > >> -- Gerhard > > > Yeah i already

Re: finding domain name

2008-09-23 Thread Tino Wildenhain
Bobby Roberts wrote: Depends on the technology/web framework. If you use WSGI, you should use something like: host_name = environ.get("HTTP_HOST", None) or environ["SERVER_NAME"] -- Gerhard Yeah i already tried environ("SERVER_NAME") but get a key error when i do. You could output the whole

Re: finding domain name

2008-09-23 Thread Bobby Roberts
On Sep 23, 8:54 am, "Joe Riopel" <[EMAIL PROTECTED]> wrote: > On Tue, Sep 23, 2008 at 8:37 AM, Bobby Roberts <[EMAIL PROTECTED]> wrote: > > hi group.  I'm new to python and need some help and hope you can > > answer this question.  I have a situation in my code where i need to > > create a file on

Re: finding domain name

2008-09-23 Thread Bobby Roberts
> Depends on the technology/web framework. If you use WSGI, you should use > something like: > > host_name = environ.get("HTTP_HOST", None) or environ["SERVER_NAME"] > > -- Gerhard Yeah i already tried environ("SERVER_NAME") but get a key error when i do. -- http://mail.python.org/mailman/listin

Re: finding domain name

2008-09-23 Thread Joe Riopel
On Tue, Sep 23, 2008 at 8:37 AM, Bobby Roberts <[EMAIL PROTECTED]> wrote: > hi group. I'm new to python and need some help and hope you can > answer this question. I have a situation in my code where i need to > create a file on the server and write to it. That's not a problem if > i hard code t

Re: finding domain name

2008-09-23 Thread Gerhard Häring
Bobby Roberts wrote: hi group. I'm new to python and need some help and hope you can answer this question. I have a situation in my code where i need to create a file on the server and write to it. That's not a problem if i hard code the path. However, the domain name needs to be dynamic so i

finding domain name

2008-09-23 Thread Bobby Roberts
hi group. I'm new to python and need some help and hope you can answer this question. I have a situation in my code where i need to create a file on the server and write to it. That's not a problem if i hard code the path. However, the domain name needs to be dynamic so it is picked up automati