Path: csiph.com!usenet.pasdenom.info!weretis.net!feeder1.news.weretis.net!feeder.erje.net!eu.feeder.erje.net!xlned.com!feeder5.xlned.com!news2.euro.net!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.004 X-Spam-Evidence: '*H*': 0.99; '*S*': 0.00; 'filename': 0.07; 'subject:file': 0.07; 'subject:form': 0.07; "'''": 0.09; 'filename.': 0.09; 'iterate': 0.09; 'to:addr:comp.lang.python': 0.09; 'tuple.': 0.09; 'cc:addr:python-list': 0.10; 'charset:iso-8859-7': 0.15; 'sys.exit(0)': 0.16; 'tabs': 0.16; 'wrote:': 0.17; 'replacing': 0.17; 'appropriate': 0.20; 'written': 0.20; 'all,': 0.21; 'supposed': 0.21; 'cc:2**0': 0.23; 'cc:no real name:2**0': 0.24; 'tried': 0.25; 'cc:addr:python.org': 0.25; 'header:In-Reply-To:1': 0.25; 'header:User-Agent:1': 0.26; 'am,': 0.27; "doesn't": 0.28; 'indentation': 0.29; 'code': 0.31; 'print': 0.32; 'received:google.com': 0.34; 'list': 0.35; 'received:209.85': 0.35; 'but': 0.36; 'received:209': 0.37; 'subject:: ': 0.38; 'most': 0.61; 'show': 0.63; 'programs,': 0.71; '2013': 0.84; 'lien': 0.84; 'matters.': 0.84; '\xcc\xe1\xf1\xf4\xdf\xef\xf5': 0.84; 'angel': 0.93 X-Received: by 10.49.63.164 with SMTP id h4mr2368759qes.39.1362479051698; Tue, 05 Mar 2013 02:24:11 -0800 (PST) Newsgroups: comp.lang.python Date: Tue, 5 Mar 2013 02:24:11 -0800 (PST) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=94.68.127.128; posting-account=DYJQ-woAAACEPH85Au2BhUVfFTfSfVa4 References: User-Agent: G2/1.0 X-Google-Web-Client: true X-Google-IP: 94.68.127.128 MIME-Version: 1.0 Subject: Re: Downloading a file form a displayed table From: =?ISO-8859-7?B?zd/q7/Igw+rxMzPq?= To: comp.lang.python@googlegroups.com Content-Type: text/plain; charset=ISO-8859-7 Content-Transfer-Encoding: quoted-printable Cc: 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 List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Message-ID: Lines: 58 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1362494522 news.xs4all.nl 6948 [2001:888:2000:d::a6]:53211 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:40532 =D4=E7 =D4=F1=DF=F4=E7, 5 =CC=E1=F1=F4=DF=EF=F5 2013 11:51:41 =F0.=EC. UTC+= 2, =EF =F7=F1=DE=F3=F4=E7=F2 Dave Angel =DD=E3=F1=E1=F8=E5: > On 03/05/2013 04:00 AM, =CD=DF=EA=EF=F2 =C3=EA=F133=EA wrote: >=20 > > >=20 > > >=20 >=20 >=20 > > for filename in os.walk(path): >=20 >=20 >=20 > But os.walk() doesn't return a filename. It returns a tuple. Have you=20 >=20 > tested any of this code outside of a server? >=20 >=20 >=20 > Also, you're using tabs here. They don't show up in most email=20 >=20 > programs, so you're better off replacing them with an appropriate number= =20 >=20 > of spaces. After all, indentation matters. >=20 >=20 >=20 >=20 >=20 > > print ''' >=20 > >
>=20 > > print( "
= " ) % filename >=20 > > >=20 > > ''' >=20 > > =09 >=20 > > sys.exit(0) >=20 > > >=20 > --=20 >=20 > DaveA How is this lien supposed to be written do to iterate over a list of filena= mes? for filename in list( os.walk(path) ): i tried the above but still it doesn't work out.