Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 938651
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T21:40:40+00:00 2026-05-15T21:40:40+00:00

I am designing a website which will involve too many photos. There are two

  • 0

I am designing a website which will involve too many photos.

There are two modules Restaurants and Dishes. which is the best way to create the directory strcuture ?

images/Restaurants/ID
images/Dishes/ID

am using the following to create the filename

function imgName($imgExtension)
  {
      return time() . substr(md5(microtime()), 0, 12) . ".".$imgExtension;
  }

ii want two different sized thumbnails. which is the best way to name the thumbnails ?

since the db will hold only the main pictures filename with extension.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-15T21:40:41+00:00Added an answer on May 15, 2026 at 9:40 pm

    I wouldn’t worry too much about the directory structure, what you have seems good, even better might be to use S3 buckets.

    As for the filename part, I’ve found the simplest way is to prepend thumb_ to the thumb filename. So: somefilename.jpg -> thumb_somefilename.jpg

    This way you can store somefilename.jpg in the database and simply add the extra part to the front when you want the thumb.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am currently designing a website in C#, which uses some very complex code
I am in the process is designing a website in ASP.NET MVC and am
I am currently in the process of designing myself a database driven website. The
I have a Ruby on Rails application that will be a CMS in way
Even before telling my question, will tell you that this is a very vague
What things should a developer designing and implementing an API for a community based
Which is better to do client side or server side validation? In our situation
Context: I'm in the design phase of what I'm hoping will be a big
I'm a software developer, and I'm going onto a project now that involves implementing

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.