I am new to php and want generate url from image id in database. I have some images in my mysql-database associated with random id eg 546ae8c6b9f9a. I want to show all images related to that image if someone visit the page www.mysite.com/546ae8c6b9f9a. Simular to this url http://sv.tinypic.com/r/v2sak3/8
How can I do that when 546ae8c6b9f9a is not a directory or real file, just a reference to which images I want to show from the database?