I have a series of photos on a server with a strict naming convention: "uniqueId-readableName.jpg". I do this because my site database currently logs a unique identifier (and some unrelated information), but sometimes people have to look at the file server directly to view photos (via FTP), so it is useful to use a readable name. for instance
001456-War Horse.jpg 003295-Sunshine Daiseys.jpg 129084-Laboring at the farm 2013-08-11.jpg
Now I'm sure the best option would be to create a database with the full file names, but I just wanted to see if anyone had any ideas that I might have missed. This question is similar to SO , but I have strict naming conventions here - I'm not sure if this opens up any possibilities or not.
I apply this to img , but the same idea can be applied to any file extension (for example, download "789-My Homework.zip" or "123-Family vacation.zip").
As an example of what I'm looking for in Windows Explorer, you can search for a file
0*.jpg
and all the following files can be returned
001456-War Horse.jpg 003295-Sunshine Daiseys.jpg 029084-Laboring at the farm 2013-08-11.jpg
In my case, the initial part is always unique, so I would like to use something like 001456-*.jpg 001456-War Horse.jpg and return it 001456-War Horse.jpg .
Is there any way to do this on a website?
<img src="001456-*.jpg" />
source share