title: File upload and confirmation page before submission
body: <p>I am trying to create a "please confirm" page before submitting the data from a form. The form has a file upload field. <strong>How do I pass the value of what is submitted in the upload field so they can confirm and click submit again?</strong></p>
  
  <p>The rest of the data I am going to post into hidden fields and echo the values so they can confirm.</p>
  
  <p>How do I accomplish this with an uploaded <code>$_FILE</code></p>
  
  <p>first page:</p>
  
  <pre><code>&lt;form action="confirm.php" method="post"&gt;
  &lt;input type="text" name="name"/&gt;
  &lt;input type="file" name="attachment"/&gt;
  &lt;input type="submit" name="submit" value="Submit"/&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>Confirm.php</p>
  
  <pre><code>&lt;form action="submit_data.php" method="post"&gt;
  Your Name: &lt;? echo $_POST['name']; ?&gt;
  &lt;input type="hidden" name="name" value="&lt;? echo $_POST['name']; ?&gt;"/&gt;
  
  //HERE IS WERE I NEED TO STORE THE FILE INFO 
  Your File Name: &lt;? echo $_FILES['attachment']['name']; ?&gt;
  &lt;input type="hidden" name="&lt;? echo $_FILES['attachment']; ?&gt;"/&gt;
  
  &lt;input type="submit" name="submit" value="Submit"/&gt;
  &lt;/form&gt;
  </code></pre>