title: JSP: Get MIME Type on File Upload
body: <p>I'm doing a file upload, and I want to get the Mime type from the uploaded file.</p>
  
  <p>I was trying to use the <strong>request.getContentType()</strong>, but when I call:</p>
  
  <pre><code>String contentType = req.getContentType();
  </code></pre>
  
  <p>It will return:</p>
  
  <blockquote>
    <p>multipart/form-data; boundary=---------------------------310662768914663</p>
  </blockquote>
  
  <p>How can I get the correct value?</p>
  
  <p>Thanks in advance</p>