referer url

Tim Chase python.list at tim.thechases.com
Mon Jan 28 18:39:18 CET 2008


> 1) CGI so i'm doing it right.

that's helpful to know

> 2) this is impossible as i'm doing the exact same thing with another
> language and it utterly works.

Just making sure...same browser/setup/configuration, different 
language?

> 3) the same as above

kinda figured...most servers give you the HTTP_REFERER, so you' 
have to

> 4) no..
> 
> this gets nerve breaking!

Well, you can always dump the contents of os.environ into your 
output to see if you can find why.

   from cgi import escape
   out.write('<br>'.join([
     '<b>%s:</b>%s' % (escape(k), escape(v))
     for k,v in os.environ.iteritems()
     ])

-tkc







More information about the Python-list mailing list