
Originally Posted by
descalzo
For images:
If the link in the Database is /uploaded/foo.jpg, make the link /display.php?p=uploaded&f=foo.jpg
Create display.php which will take the query string and create a page with the image embedded.
You could also do something similar with text files (which would also work with images. display.php would create output a template page with an iframe. The source of the iframe would be /uploaded/filename.txt
Either way, make sure to test the query string to make sure you end up pointing to an uploaded file and not something you do not want displayed.