title: failed to open stream: No such file or directory
body: <p>Can anyone help with this one? I am new to web developing and not sure what this error means?</p>
  
  <blockquote>
    <p>Warning: fopen(images/nophoto.png): failed to open stream: No such
    file or directory in /home/u835626360/public_html/remove.html on line
    101</p>
  </blockquote>
  
  <p>can't this file/picture is open you need close</p>
  
  <p>CODE:</p>
  
  <pre><code>$expire=time()-3600;
  setcookie("dname","a", $expire);
  setcookie("dpode","a", $expire);
  }
  function delpics($filename)
  {
  $path_to_file='userpics/';
  $old = getcwd(); // Save the current directory
      chdir($path_to_file);
      $fh = fopen($filename, 'w') or die("can't this file/picture is open you need close ");
      fclose($fh);
      if (!unlink($filename))
    {
    echo ("Error deleting $file");
    }
  else
    {
    echo ("Deleted  $filename");
    }
      chdir($old); // Restore the old working directory   
  }
  </code></pre>