Jump to content
  • Advertisement
Sign in to follow this  
Zumichu

[web] Image Management

This topic is 5028 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I'm looking for ideas on how to handle managing a database of images for a website. Basically, users will be able to post pictures in multiple formats for a variety of reasons. I assume I will assign an id to each image and probably rename the file to that id. For increased speed, I've heard the best thing to do is store the files in multiple directories in the filesystem, such as directories 1-9 and sort the files into their directories based on id. Then in the database I would store the id, timestamp, user that submitted the pic, id of what part of the site it belongs to, and maybe a text description. I feel like I'm on the right track, but I'd like to hear from anyone who has done something like this before or anyone else that has some ideas. Thanks.

Share this post


Link to post
Share on other sites
Advertisement
I did something similar to a CMS site I designed for a client. It sounds as if you're on the right track. The system I designed assigned an ID to the file (based on time/date of the file uploaded) and copied it into a folder based on the location on the site. So if the image belonged in "articles" it was put into a folder to reflect this. The database held the original filename of the file which was then reinstated should the user want to download the image. It worked pretty well for me.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!