views:

45

answers:

1

What's the general rule of thumb while naming dynamic / user-uploaded images. For instance, profile pictures.

Is there a benefit for filenames to be human-readable (joshmason_profile.jpg) and not something random (sjdir2311.jpg)?

And how do you organize them? All in a single folder with filenames in database? or dynamically generated folders (say one for each user)?

+1  A: 

In our application we name files with a unique id generated from the database and keep those files in a single folder.

Generating a folder for each and every user will be a tedious task.

rahul