title: Find file MYME-TYPE by using file finfo_file
body: <p>I am using xampplite1.7.2 which using PHP5.3.0 I am trying to find the file MIME type. But its giving me error:</p>
  
  <blockquote>
    <p>Call to undefined function
    finfo_open()</p>
  </blockquote>
  
  <p>I read the PHP Manual its says that this function support in PHP 5.3 and as i mention that i am using xampplite1.7.2 which using PHP5.3 then why this error occur. I also used </p>
  
  <blockquote>
    <p>$_FILES['image']['type']</p>
  </blockquote>
  
  <p>Which is showing me the type correctly. I am very confuse that many people i found told different ways to get MIME-TYPE by using <strong>Fileinfo</strong> and <strong>getimagesize()</strong> but none refers to <strong>$_FILES['image']['type']</strong>.
  What is the difference in all these functions.
  Actually i created doc file and then i changed it to JPG by changing its extension. My problem is that when i check the MIME type by using <strong>$_FILES['image']['type']</strong> Its showing me <strong>image/jpeg</strong> is this showing the correct MIME_type and if i use other methods will they show me the correct type of this file which is a .doc file. Because i need to find a way to get the correct type of this file which was .doc.
  What are the ways to find solve this issue because i am keep trying to solve this issue sine last 24 hours but it seems very difficult to find MIME-type in PHP. i am not very exercised in working with PHP. SO please someone help me to solve this problem.
  Actually i want to find that the given file is a valid image file or not.
  Thanks </p>