View Full Version : How should I file my files?

04-25-2010, 04:55 AM

I've always put my stuff up on the web using a folder named assets for graphics, photos for photos, css for css and so on and so forth.

Would it be easier for me to make each page its own directly level?

index.html (and all graphics on the index page)

----- all files for about me, photos graphics used on this page.
----- all files for about me, photos graphics used on this page.

Although after posting this I think just keeping it the original way works best. I just wanted some outside input!

Thanks for the advise!

code beginner
04-25-2010, 04:58 AM
not sure exactly what you mean, but if the site isn't too large, you don't have to get crazy with tons of folders.

if you are working by yourself, you only have to answer this question: what makes life easier for you?

the web server will find the files quickly anyway. so do what makes sense for you.

if you have hundreds of images for one website, then you might want to place them into separate, page-specific folders. but if you are only dealing with 20 images or so, then it's easier put them all in the same folder.

04-25-2010, 06:05 AM
I don't know what the perfect solution is. As long as there is organization that makes sense and easy to locate. It's no fun going through a few thousand files and folders trying to find something. I tend to avoid creating deep folders/directories. I think going too deep is harder to manage, doesn't look so good in a web browser. I don't know how well some of the search engines find deeper linking. If they can handle it all or not. I try not to go over 4 directory / folders deep if possible.

04-25-2010, 03:16 PM
Thanks for your insight. I just wanted to get a grip on what others do. I'll just keep doing what I do! :thumbsup:

04-25-2010, 11:34 PM
Are you running a db-driven site where MySQL for example is used to store data?

if so, you can put all images etc into one directory and store the image names in the db related to the page ~ or something other criterion that makes sense for your app.