Jump to content

File/Folder limit


XAlliedYouthX

Recommended Posts

I'm working on a site that could potentially have thousands of users with many images each.  I'm wondering what the recommended structure for the possible expansion could be.  I know that having all the images in one directory is easiest but I know there will be a file limit at some point.  One idea I had was to have every 1000 or so users "grouped" under directories but I really don't know if that's best.  Can someone recommend what might be the best structure to use?

Link to comment
https://forums.phpfreaks.com/topic/131263-filefolder-limit/
Share on other sites

I know that having all the images in one directory is easiest but I know there will be a file limit at some point.

 

There is no file limit per say, you just run out of discspace. In fact there is a limit to the depth of your directory structures depending on your filesystem.

 

The question is probably more related to organization. One method you could use would be to create a directory tree something like....

 

[pre]

images/

  a/

    andrew/

      foo.jpg

      bar.jpg

    alex/

  b/

    bob/

      foo.jpg

  c/

  d/

  e/

[/pre]

 

etc etc.

 

This will also help with filename collisions between different users files.

Link to comment
https://forums.phpfreaks.com/topic/131263-filefolder-limit/#findComment-681520
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.