1

Possible Duplicates:
Get MIME Type via PHP
How can I get the mime type in PHP

Hi all , I have a bunch of xxx.file files . is there any method in PHP i can get the MIME type of them ?

they vary from JPEG SWF AVI FLV ... but the extention is one *.file

Thank you

Community
  • 1
  • 1
Rami Dabain
  • 4,709
  • 12
  • 62
  • 106
  • 2
    You have two separate problems: (1) identify each file's format based on its contents and (2) map each file format to a MIME type. The second one is trivial, but in the general case the first one is "unsolvable" because no program can have knowledge of all the file formats in the universe. You will have to constrain and clearly define your requirements before you can work out a solution. – Jon May 07 '11 at 12:02

0 Answers0