Website folder structure

Discussion in 'HTML & Website Design' started by fadetoblack22, Jul 8, 2009.

  1. #1
    I have too many file in one of my folders so I want to split it down into subfolders.

    e.g. folder1/ has 100 files

    I want to make it so its like folder1/folderA, folder1/folderB, folder1/folderC

    However I have no natural index file for each of the A, B, C.

    At the moment I have just put a blank file in so that people can't access the files in the directory.

    My question is what is the best way to deal with this other than putting content for the sake of it on the blank index file?

    There is an important file in each of the directories. Is there a way that going to FolderA for example would open the important file as default?


    thanks.

    Edit: after thinking, the best way to do this is probably put a .htaccess folder in each of these directories to redirect it to the important page rather than the index file in the folder.
    Could someone advise me on this please?
     
    fadetoblack22, Jul 8, 2009 IP
  2. Canonical

    Canonical Well-Known Member

    Messages:
    2,223
    Likes Received:
    141
    Best Answers:
    0
    Trophy Points:
    110
    #2
    Can you give real examples of the of the URLs for the files and folder names EXCEPT be SURE to use www.example.com for the domain instead of your real domain? It's hard to picture exactly what your problem is so that I can suggest a solution (or two).
     
    Canonical, Jul 8, 2009 IP
  3. ian_batten

    ian_batten Well-Known Member

    Messages:
    1,991
    Likes Received:
    106
    Best Answers:
    0
    Trophy Points:
    185
    #3
    Why don't you simply rename the important files, to index.php?
     
    ian_batten, Jul 8, 2009 IP
  4. fadetoblack22

    fadetoblack22 Well-Known Member

    Messages:
    2,399
    Likes Received:
    62
    Best Answers:
    0
    Trophy Points:
    160
    #4
    The important file has a file name that helps its seo.
     
    fadetoblack22, Jul 9, 2009 IP
  5. fadetoblack22

    fadetoblack22 Well-Known Member

    Messages:
    2,399
    Likes Received:
    62
    Best Answers:
    0
    Trophy Points:
    160
    #5
    Yeh sure,

    FolderA = Football/

    The files in it are Premiership.php, Championship.php etc...

    I don't have a general page about football so the index is blank. I was thinking of redirecting the index to Premiership.php
     
    fadetoblack22, Jul 9, 2009 IP
  6. ian_batten

    ian_batten Well-Known Member

    Messages:
    1,991
    Likes Received:
    106
    Best Answers:
    0
    Trophy Points:
    185
    #6
    Okay, well how about you do this.

    Say you had football/footballa/champisonship.php

    Change it to, football/footballa/championship/index.php?

    Means you still have the keyword in the domain, with no kind of redirect.
     
    ian_batten, Jul 9, 2009 IP
  7. fadetoblack22

    fadetoblack22 Well-Known Member

    Messages:
    2,399
    Likes Received:
    62
    Best Answers:
    0
    Trophy Points:
    160
    #7
    That doesn't really work because for every file inside the folder there now has to be an extra folder with just one file in it. So it would mean 100+ extra folders with 1 file in them.
     
    fadetoblack22, Jul 10, 2009 IP
  8. ian_batten

    ian_batten Well-Known Member

    Messages:
    1,991
    Likes Received:
    106
    Best Answers:
    0
    Trophy Points:
    185
    #8
    True, but would solve your problem.
     
    ian_batten, Jul 10, 2009 IP