Forcing Python to detect DocumentRoot

Joel Goldstick joel.goldstick at gmail.com
Wed Jan 16 15:39:43 CET 2013


On Wed, Jan 16, 2013 at 9:32 AM, Ferrous Cranus <nikos.gr33k at gmail.com>wrote:

> Τη Τετάρτη, 16 Ιανουαρίου 2013 4:01:07 μ.μ. UTC+2, ο χρήστης Joel
> Goldstick έγραψε:
> > On Wed, Jan 16, 2013 at 8:51 AM, Ferrous Cranus <nikos... at gmail.com>
> wrote:
> >
> > When trying to open an html template within Python script i use a
> relative path to say go one folder back and open index.html
> >
> >
> >
> >
> > f = open( '../' + page )
> >
> >
> >
> > How to say the same thing in an absolute way by forcing Python to detect
> DocumentRoot by itself?
> >
> > --
> >
> > http://mail.python.org/mailman/listinfo/python-list
> >
> >
> >
> > I don't think I understand your question.  But, I think your answer is
> here:
>
> Nowhere that page says something about python detecting documentroot
> directory (www or public_html) that is.
>

What is DocumentRoot?  This is a convention, not something a language would
'know' about

> --
> http://mail.python.org/mailman/listinfo/python-list
>



-- 
Joel Goldstick
http://joelgoldstick.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20130116/aaf0a6cf/attachment.html>


More information about the Python-list mailing list