Is it possible to use multiple header types in one document? For example:
header(\"Content-type: image/jpeg\");
header(\'Content-Type: text/html; charset=utf
Be careful about what parameters you are passing to the wrapper file, in order that it finds the relevant image, and ONLY the relevant image, not /etc/passwd or any other file.
It's best to hard code the base dir in the script and don't accept any hierarchy in the input. It's probably best to not use real filenames at all and do the lookup in a mapping table (in a db, array in your script or wherever)