title: Save file with file_put_contents in folder
body: <pre><code>file_put_contents('image.jpg',file_get_contents('http://static.adzerk.net/Advertisers/12f0cc69cd9742faa9c8ee0f7b0d210e.jpg'));
  </code></pre>
  
  <p>Saving the file in current folder is working ok, but if I try</p>
  
  <pre><code>file_put_contents('/subfolder/image.jpg',file_get_contents('http://static.adzerk.net/Advertisers/12f0cc69cd9742faa9c8ee0f7b0d210e.jpg'));
  </code></pre>
  
  <p>I have an error:</p>
  
  <blockquote>
    <p>failed to open stream: No such file or directory in […]</p>
  </blockquote>
  
  <p>Why does this error occur? How can I save the file in a subfolder?</p>