PDA

View Full Version : a generated html page of links?



Peegee
08-01-2003, 12:25 AM
let's say, hypothetically, I had several folders of files I want to host online. Instead of writing 200 lines of code, or whatever it is (even though most of the lines are duplicate except for the numbers), could I generate a webpage which has the files all linked?

k thx bai

Citizen Bleys
08-01-2003, 01:52 AM
It's possible, but I don't know an algorithm for it off the top of my head.

Of course, if the files are named sequentially (i.e., image0.gif, image1.gif, image2.gif) etc., it would be PAINFULLY easy to write a program to generate the HTML page in Pascal...but the HTML wouldn't be generated server-side, you'd have to generate it and then upload it, and then re-generate the page every time you wanted to update it. PITA factor = high.

Endless
08-01-2003, 02:01 AM
Or you can try PHP.
It has directory <a href="http://www.php.net/manual/en/ref.dir.php"> functions</a>.

Dr Unne
08-01-2003, 02:09 AM
Perl would do it. Learn Perl. Use the CGI module.

Peegee
08-01-2003, 02:28 AM
Bleys, the hosting is on my computer so updating is a cynch....synch...something easily accomplishable.

I'll take a look at perl. php sounds awfully difficult.

Dr Unne
08-01-2003, 02:43 AM
PHP is probably easier for something like this. But oh so much less fun.