redirect to a new page once file upload is finished
<p>I have got the following php file for my file upload, how do I redirect to a new page once the file is finished upload, thanks in advance.</p>

<pre><code>&lt;?php
echo &lt;&lt;&lt;_END
&lt;html&gt;

&lt;title&gt;PHP Form Upload&lt;/title&gt;&lt;/head&gt;&lt;body&gt;
&lt;form method = 'post' action='testupload.php' enctype='multipart/form-data'&gt;
Select File: &lt;input type='file' name='filename' size='10' /&gt;
&lt;input type='submit' value='Upload' /&gt;
&lt;/form&gt;


_END;


 if($_FILES)
{
$a = uniqid();
   $saveto =  $a.".jpg";;
 // $name = $_FILES['filename']['name'];
  move_uploaded_file($_FILES['filename']['tmp_name'],  $saveto);
  $typeok = TRUE;

  switch($_FILES['filename']['type'])
   {
     case "image/gif": $src = imagecreatefromgif($saveto); break;

       case "image/jpeg":
         case "image/pjpeg":  $src = imagecreatefromjpeg($saveto); break;

      case "image/png": $src = imagecreatefrompng($saveto); break;

       default: $typeok = FALSE; break;
    }


     echo "Upload image '$saveto'&lt;br/&gt;&lt;img src='$saveto' /&gt;";
  }
  if ($_FILES["filename"]["size"] &gt; 2000)
     {
      echo "Error: file is too big" . $_FILES["file"]["error"] . "&lt;br /&gt;";
     }

  echo"&lt;/body&gt;&lt;/html&gt;";

   ?&gt;    
</code></pre>
