title: PHP mailer error : failed to open stream: No such file or directory
body: <p>Hello there I receive following error while try to upload file using php mailer.</p>
  
  <p><strong>move_uploaded_file(C:/inetpub/vhosts/yoursite.com/httpdocs/userfiles/resumes/5007story1.pdf) [function.move-uploaded-file]: failed to open stream: No such file or directory in D:\yoursite\wwwroot\jobseekers.php on line 87</strong></p>
  
  <pre><code>            global $imagesname;
          global $image_type;   
          $uid = rand(100,9999);
          if(isset($_FILES["img"]["name"]))
          {
              $image_tempname= $_FILES['img']['name'];
  
              $imgdir ="C:/inetpub/vhosts/yoursite.com/httpdocs/";// $_SERVER ["DOCUMENT_ROOT"];
              //imgdir =$_SERVER ["DOCUMENT_ROOT"];
              $imgname = $imgdir. 'userfiles/resumes/'.$uid.$_FILES['img']['name'];
  
              if($imagesname != '')
              {
                  $imagesname=$imagesname.','.$imgname;
                  $image_type=$image_type.','.$_FILES['img']['type'];
              }
              else
              {
                  $imagesname=$imagesname.$imgname;
                  $image_type=$image_type.$_FILES['img']['type'];
              }
              $imgurl = 'userfiles/resumes/'.$image_tempname;     
              //print_r($_SERVER['PATH_TRANSLATED']);
  
              move_uploaded_file ($_FILES['img']['tmp_name'], $imgname); 
  
          }
          if(isset($_FILES["img"]['name']))
          {
              $filename=$uid.$_FILES["img"]["name"];
          }
          $fileField=$filename;
  </code></pre>
  
  <p>Line Number 87 Is:
  <strong>move_uploaded_file ($_FILES['img']['tmp_name'], $imgname);</strong> </p>