The Web Design Group

... Making the Web accessible to all.

Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
> How do I read files names?
dmak
post Jan 11 2008, 04:24 AM
Post #1


Newbie
*

Group: Members
Posts: 19
Joined: 2-January 08
Member No.: 4,626



I am building a gallery script for myself and I need some help. Please don't suggest me to use already made gallery scripts. I do not want to argue why.

Lets say my website is...

smile.com/

Smile.com/albums/

So, I created a set of tables where it is only created if there is a folder under ablums. For ex, lets say i have Pokemon under albums. It will create this

CODE

<table>
  <tr>
    <td>
      Pokemon (AKA Box 1)
    </td>
  </tr>
  <tr>
    <td>
      test2
      </td>
  </tr>
  <tr>
    <td>
      test3
    </td>
  </tr>
</table>

So remember my folder was called pokemon. In box 1, I want it to say Pokemon. Let me give 1 more example.

Ok, so now I create a new folder under smile.com/albums/ called Power. Upon creating the folder it will also create (by itself) a new set of tables.


CODE

<table>
  <tr>
    <td>
      Power (aka box 1)
    </td>
  </tr>
  <tr>
    <td>
      test2
      </td>
  </tr>
  <tr>
    <td>
      test3
    </td>
  </tr>
</table>


How can I do this?

This post has been edited by dmak: Jan 11 2008, 04:26 AM
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
Brian Chandler
post Jan 11 2008, 05:31 AM
Post #2


Jocular coder
********

Group: Members
Posts: 2,460
Joined: 31-August 06
Member No.: 43



QUOTE
So, I created a set of tables where *it* is only created if there is a folder under ablums. For ex, lets say i have Pokemon under albums. It will create this


Can't really understand your question. What is the "it" (marked * *) above? How have you created this set of tables, and where are they?

User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
moo
post Jan 11 2008, 07:52 AM
Post #3


Member
***

Group: Members
Posts: 46
Joined: 12-September 07
Member No.: 3,783



I *think* you want to be able to generate a HTML table for each folder that exists in your filesystem? Any server-side language (such as ASP, JSP, PHP) can be used to traverse directories and output the folder and/or filenames.

This post has been edited by moo: Jan 11 2008, 07:52 AM
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
dmak
post Jan 11 2008, 02:36 PM
Post #4


Newbie
*

Group: Members
Posts: 19
Joined: 2-January 08
Member No.: 4,626



QUOTE(moo @ Jan 11 2008, 07:52 AM) *

I *think* you want to be able to generate a HTML table for each folder that exists in your filesystem? Any server-side language (such as ASP, JSP, PHP) can be used to traverse directories and output the folder and/or filenames.


Exactly! How can I do this?
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
Darin McGrew
post Jan 11 2008, 03:00 PM
Post #5


WDG Member
********

Group: Root Admin
Posts: 8,365
Joined: 4-August 06
From: Mountain View, CA
Member No.: 3



What kind(s) of server-side programs can you run? CGI? PHP? ASP?

What programming experience do you have?

The simplest approach would be to configure your server to generate the index pages automatically. Apache gives you a fair bit of control over what its automatically generated index pages look like.
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
dmak
post Jan 11 2008, 03:07 PM
Post #6


Newbie
*

Group: Members
Posts: 19
Joined: 2-January 08
Member No.: 4,626



I want to use php. It's the most experience I have in out of the languages you listed, but very little experience. I do know a bit of C++.
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
dmak
post Jan 11 2008, 06:34 PM
Post #7


Newbie
*

Group: Members
Posts: 19
Joined: 2-January 08
Member No.: 4,626



OK, scratch everything. I have most of it done now.

User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post

Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



- Lo-Fi Version Time is now: 28th March 2024 - 07:40 AM