File typing

From: Date: Fri, 24 May 2002 19:13:26 +0000
Subject: File typing
Groups: php.general 
Request: Send a blank email to php-general+get-99132@lists.php.net to get a copy of this message
Hi, Does anyone know if there are functions in PHP or an extension for getting the mime type (and possibly a description) of ANY kind of file? I know that the array that the getimagesize() function returns has an image type field, but I'd like to be able to determine the appropriate file type for use with a Content-Type: header for any (or at least the most common) file types, plus be able to pull a description of the data similar to how the 'file' command works using the 'magic' file. Derek -- Derek Piper (dpiper@stens.com) Systems Administrator - Stens Corporation

« previous php.general (#99132) next »