Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #36898

Re: Forcing Python to detect DocumentRoot

Path csiph.com!newsfeed.hal-mli.net!feeder3.hal-mli.net!newsfeed.hal-mli.net!feeder2.hal-mli.net!newsfeed.xs4all.nl!newsfeed2.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail
Return-Path <nikos.gr33k@gmail.com>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.031
X-Spam-Evidence '*H*': 0.94; '*S*': 0.00; '16,': 0.03; 'subject:Python': 0.05; 'python': 0.09; 'forcing': 0.09; 'to:addr:comp.lang.python': 0.09; 'cc:addr:python-list': 0.10; 'template': 0.11; 'index.html': 0.16; 'wed,': 0.16; 'wrote:': 0.17; 'detect': 0.17; 'jan': 0.18; 'trying': 0.21; 'cc:2**0': 0.23; 'absolute': 0.23; 'script': 0.24; 'cc:addr:python.org': 0.25; 'header:In-Reply-To:1': 0.25; 'header:User-Agent:1': 0.26; 'am,': 0.27; 'url:mailman': 0.29; 'folder': 0.30; 'relative': 0.30; 'url:python': 0.32; 'url:listinfo': 0.32; 'says': 0.33; 'received:google.com': 0.34; 'path': 0.35; 'open': 0.35; 'received:209.85': 0.35; 'something': 0.35; 'url:org': 0.36; 'received:209': 0.37; 'received:209.85.216': 0.37; 'subject:: ': 0.38; 'page': 0.38; 'url:mail': 0.40; 'think': 0.40; 'your': 0.60; 'here:': 0.62; 'back': 0.62; 'is.': 0.62; 'within': 0.64; '8bit%:100': 0.70; '8bit%:92': 0.70; '(www': 0.84; '2013': 0.84; 'detecting': 0.84; 'itself?': 0.84; 'joel': 0.91
X-Received by 10.182.77.202 with SMTP id u10mr18972obw.14.1358346764474; Wed, 16 Jan 2013 06:32:44 -0800 (PST)
Newsgroups comp.lang.python
Date Wed, 16 Jan 2013 06:32:42 -0800 (PST)
In-Reply-To <mailman.568.1358344869.2939.python-list@python.org>
Complaints-To groups-abuse@google.com
Injection-Info glegroupsg2000goo.googlegroups.com; posting-host=199.167.138.130; posting-account=DYJQ-woAAACEPH85Au2BhUVfFTfSfVa4
References <339d9d6d-b000-4cf3-8534-375e0c44b2ca@googlegroups.com> <mailman.568.1358344869.2939.python-list@python.org>
User-Agent G2/1.0
X-Google-Web-Client true
X-Google-IP 199.167.138.130
MIME-Version 1.0
Subject Re: Forcing Python to detect DocumentRoot
From Ferrous Cranus <nikos.gr33k@gmail.com>
To comp.lang.python@googlegroups.com
Content-Type text/plain; charset=UTF-8
Content-Transfer-Encoding quoted-printable
Cc "python-list@python.org" <python-list@python.org>
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.15
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <http://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list/>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <http://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Message-ID <mailman.572.1358347492.2939.python-list@python.org> (permalink)
Lines 31
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1358347492 news.xs4all.nl 6925 [2001:888:2000:d::a6]:51142
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:36898

Show key headers only | View raw


Τη Τετάρτη, 16 Ιανουαρίου 2013 4:01:07 μ.μ. UTC+2, ο χρήστης Joel Goldstick έγραψε:
> On Wed, Jan 16, 2013 at 8:51 AM, Ferrous Cranus <nikos...@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.

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Forcing Python to detect DocumentRoot Ferrous Cranus <nikos.gr33k@gmail.com> - 2013-01-16 05:51 -0800
  Re: Forcing Python to detect DocumentRoot Joel Goldstick <joel.goldstick@gmail.com> - 2013-01-16 09:01 -0500
    Re: Forcing Python to detect DocumentRoot Ferrous Cranus <nikos.gr33k@gmail.com> - 2013-01-16 06:32 -0800
      Re: Forcing Python to detect DocumentRoot Joel Goldstick <joel.goldstick@gmail.com> - 2013-01-16 09:39 -0500
    Re: Forcing Python to detect DocumentRoot Ferrous Cranus <nikos.gr33k@gmail.com> - 2013-01-16 06:32 -0800
  Re: Forcing Python to detect DocumentRoot Ferrous Cranus <nikos.gr33k@gmail.com> - 2013-01-17 01:03 -0800
  Re: Forcing Python to detect DocumentRoot rusi <rustompmody@gmail.com> - 2013-01-17 05:51 -0800
  Re: Forcing Python to detect DocumentRoot Roy Smith <roy@panix.com> - 2013-01-17 09:09 -0500
    Re: Forcing Python to detect DocumentRoot Joel Goldstick <joel.goldstick@gmail.com> - 2013-01-17 10:14 -0500
      Re: Forcing Python to detect DocumentRoot Ferrous Cranus <nikos.gr33k@gmail.com> - 2013-01-18 05:02 -0800
        Re: Forcing Python to detect DocumentRoot Joel Goldstick <joel.goldstick@gmail.com> - 2013-01-18 08:28 -0500
          Re: Forcing Python to detect DocumentRoot Ferrous Cranus <nikos.gr33k@gmail.com> - 2013-01-18 10:58 -0800
            Re: Forcing Python to detect DocumentRoot Joel Goldstick <joel.goldstick@gmail.com> - 2013-01-18 14:11 -0500
            Re: Forcing Python to detect DocumentRoot Chris Angelico <rosuav@gmail.com> - 2013-01-19 08:34 +1100
              Re: Forcing Python to detect DocumentRoot Ferrous Cranus <nikos.gr33k@gmail.com> - 2013-01-19 00:01 -0800
                Re: Forcing Python to detect DocumentRoot Michael Torrie <torriem@gmail.com> - 2013-01-21 11:49 -0700
              Re: Forcing Python to detect DocumentRoot Ferrous Cranus <nikos.gr33k@gmail.com> - 2013-01-19 00:01 -0800
                Re: Forcing Python to detect DocumentRoot Piet van Oostrum <piet@vanoostrum.org> - 2013-01-19 21:01 +0100
                Re: Forcing Python to detect DocumentRoot Ferrous Cranus <nikos.gr33k@gmail.com> - 2013-01-20 22:25 -0800
                Re: Forcing Python to detect DocumentRoot Dave Angel <d@davea.name> - 2013-01-21 07:33 -0500
                Re: Forcing Python to detect DocumentRoot Ferrous Cranus <nikos.gr33k@gmail.com> - 2013-01-21 06:55 -0800
                Re: Forcing Python to detect DocumentRoot Michael Torrie <torriem@gmail.com> - 2013-01-21 11:42 -0700
                Re: Forcing Python to detect DocumentRoot Ferrous Cranus <nikos.gr33k@gmail.com> - 2013-01-21 06:55 -0800
          Re: Forcing Python to detect DocumentRoot Ferrous Cranus <nikos.gr33k@gmail.com> - 2013-01-18 10:58 -0800
        Re: Forcing Python to detect DocumentRoot Rodrick Brown <rodrick.brown@gmail.com> - 2013-01-18 08:41 -0500
          Re: Forcing Python to detect DocumentRoot Ferrous Cranus <nikos.gr33k@gmail.com> - 2013-01-18 12:49 -0800
          Re: Forcing Python to detect DocumentRoot Ferrous Cranus <nikos.gr33k@gmail.com> - 2013-01-18 12:49 -0800
        Re: Forcing Python to detect DocumentRoot Michael Torrie <torriem@gmail.com> - 2013-01-21 08:46 -0700
          Re: Forcing Python to detect DocumentRoot Ferrous Cranus <nikos.gr33k@gmail.com> - 2013-01-21 08:02 -0800
            Re: Forcing Python to detect DocumentRoot Michael Torrie <torriem@gmail.com> - 2013-01-21 11:36 -0700
          Re: Forcing Python to detect DocumentRoot Ferrous Cranus <nikos.gr33k@gmail.com> - 2013-01-21 08:02 -0800
            Re: Forcing Python to detect DocumentRoot Piet van Oostrum <piet@vanoostrum.org> - 2013-01-21 20:05 +0100
      Re: Forcing Python to detect DocumentRoot Ferrous Cranus <nikos.gr33k@gmail.com> - 2013-01-18 05:02 -0800
  Re: Forcing Python to detect DocumentRoot Barry Scott <barry@barrys-emacs.org> - 2013-01-19 11:40 +0000
  Re: Forcing Python to detect DocumentRoot alex23 <wuwei23@gmail.com> - 2013-01-19 17:53 -0800

csiph-web