🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.nativeapi
Article #13061

Re: HTTP directory listing

#13061
From: Hans Galema
Date: Fri, 31 Oct 2003 23:59
21 lines
2046 bytes
CS wrote:

> Which is the best way to download all the files in a remote directory
> through HTTP, if I don't know their names or how many they are? 

If you don't know the names it cannot be done.

 > Can it be
> done or do I have to know that before I can do it?

If you specify a directory in the url for the webserver, than most webservers
will look for a file index.htm(l) or default.htm(l). The webmaster can
specify other files to look for. If no such file is found the webserver will
(as others already explained to you) produce a html page containing links
to all the files and directories in that directory. If you get that file
you can parse it for the filenames. As you then know the filenames you
can download them with http. The webmaster however can instruct the
webseverr not to produce directory listings if a default file is not found
(as others already told you).

Hans.
Technical Details
Message-ID: <3fa2f69b$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!news.maxwell.syr.edu!skynet.be!skynet.be!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail
References: <3fa2a041@newsgroups.borland.com> <3fa2b389@newsgroups.borland.com> <3fa2b5e1$3@newsgroups.borland.com> <3fa2eb96$2@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 10cc67,af8b744a5697d84d
X-Google-Attributes: gid10cc67,public
X-Google-ArrivalTime: 2003-10-31 16:09:20 PST
Date: Sat, 01 Nov 2003 00:59:19 +0100
From: Hans Galema <dontusethis@dontusethis.nl>
User-Agent: Mozilla/5.0 (Windows; U; Win98; en-US; rv:1.3.1) Gecko/20030425
X-Accept-Language: en-us, en
MIME-Version: 1.0
Newsgroups: borland.public.cppbuilder.nativeapi
Subject: Re: HTTP directory listing
References: <3fa2a041@newsgroups.borland.com> <3fa2b389@newsgroups.borland.com> <3fa2b5e1$3@newsgroups.borland.com> <3fa2eb96$2@newsgroups.borland.com>
In-Reply-To: <3fa2eb96$2@newsgroups.borland.com>
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 7bit
NNTP-Posting-Host: 129.125.108.11
Message-ID: <3fa2f69b$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1067644571 129.125.108.11 (31 Oct 2003 15:56:11 -0700)
Lines: 22
Path: arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!news.maxwell.syr.edu!skynet.be!skynet.be!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail