title: 2 input files in one form
body: <p>Is it possible to have something like the following</p>
  
  <pre><code>&lt;form id="uploadForm" action="" method="post" enctype="multipart/form-data"&gt;
  &lt;p&gt;Upload File 1&lt;/p&gt;
  &lt;input type="file" name="profile"/&gt;
  &lt;p&gt;Upload File 2&lt;/p&gt;
  &lt;input type="file" name="cover"/&gt;
  &lt;input type="submit" value="Submit" /&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>I then have some php script looking like:</p>
  
  <pre><code>if (empty($_POST['save']) === false) {
  
  // FOR PROFIL CHANGE
  if (isset($_FILES['profile']) === true){
  $allowed= array('jpg', 'jpeg', 'png', 'bmp');
  
  $file_name = $_FILES['profile']['name']; //name of the file
  $file_exts = explode('.', $file_name); // extension of the file
  $file_extn = strtolower(end($file_exts)); //inlowercase
  $file_temp = $_FILES['profile']['tmp_name'];
  $id = $user_data['id'];
  change_image2($id, $file_temp, $file_extn);
  }
  // FOR COVER CHANGE
  if (isset($_FILES['cover']) === true){
  $allowed= array('jpg', 'jpeg', 'png', 'bmp');
  
  $file_name = $_FILES['cover']['name']; //name of the file
  $file_exts = explode('.', $file_name); // extension of the file
  $file_extn = strtolower(end($file_exts)); //inlowercase
  $file_temp = $_FILES['cover']['tmp_name'];
  $id = $user_data['id'];
  change_image3($id, $file_temp, $file_extn);
  
  }
  </code></pre>
  
  <p>But if I upload just one file ( cover for example ); it is saved also in profile for some reason ...
  If find this weird because i gave different names to the inputs.
  Can anybody explain the problem please?</p>