Re: [phplib] protecting served files/images/mp3.... From: Eric Ries (eric.ries <email protected>)
Date: 05/22/01

On Tue, 22 May 2001, Arno A. Karner wrote:

> > I'm doing essentially the same thing with gifs stored in a database, and it
> > works like a charm, and the html is simple:
> >
> > <img src="foo.php">
> >

I once did something similar. I found it best to do something like:

foo.php/filename.gif

that way, the browser can glean information about they file type by
inspectinge the file extension (the browser doesn't know a script is
involved) and you can inspect the PATH_INFO variable in PHP to know which
file is expected.

Eric

---------------------------------------------------------------------
To unsubscribe, e-mail: phplib-unsubscribe <email protected>
For additional commands, e-mail: phplib-help <email protected>