title: Laravel-fopen: failed to open stream: Permission denied
body: <p>I'm trying to upload an image to laravel's /storage directory. I'm getting an error</p>
  
  <blockquote>
    <p>fopen(C:\Temp\AppName\public): failed to open stream: Permission denied</p>
  </blockquote>
  
  <p>This is the code i'm using to upload the image</p>
  
  <pre><code> public  function SaveImage($image){       
      $fileName = time() . '.' . $image-&gt;getClientOriginalExtension();
      $path =$image-&gt;storeAs('images/users', $fileName);
      return $fileName;
  }
  </code></pre>
  
  <p>I have given the permission for IUSR and IIS_USER, so I don't understand how it is a permission error.
  <strong>Image uploading works perfectly fine on window 10(IIS 10) and fails on window 7(IIS 7) with permission denied.</strong></p>
  
  <p>Im using laravel 5.7 and php 7.2.11.</p>
  
  <p>Any help is appreciated, Thank you.</p>