mercredi 25 novembre 2015

What are ways to generate generic Image URL for application [duplicate]

What is the best way to generate generic Image URL for a web application?

  • I store my images on the file system The metadata for the image is stored in the database.

  • whats the best way for create a generic URL for the image as I believe exposing ID of the images would not be a good solution nor the file system path also.

  • I am thinking something like creating a random string associated with the image and store it in db and expose that string in URL

  • Craigslist seems to be doing something like that, for example

http://ift.tt/1YtURO5 char][11 char][resolution].jpg

i.e

http://ift.tt/1kTfswU

So what are these "5 char" and "11 char" here?

Thanks




Aucun commentaire:

Enregistrer un commentaire