title: levrage caching in nginx 404 not found error
body: <p>after adding caching setting to my server block some of the images does't load and it send 404 not found error</p>
  
  <pre><code>    location ~*  \.(jpg|jpeg|png|gif|ico|css|js)$ {
          expires 365d;
          add_header Pragma public;
          add_header Cache-Control "public";
      }
  
      location ~*  \.(pdf)$ {
          expires 30d;
      }
  </code></pre>
  
  <p>example</p>
  
  <blockquote>
    <p>src="/laravel-filemanager/photos/2/path/path-path/my-file.jpg</p>
  </blockquote>
  
  <p>and example of another file which is loaded</p>
  
  <blockquote>
    <p>src="img/main-page.gif"</p>
  </blockquote>
  
  <p>info</p>
  
  <p><strong>web server: nginx,
  framwork: laravel,laravel file manager: unisharp</strong></p>
  
  <p>I don't know whether the problem is about the deep path or because of that path are stored in databases, or maybe it is because of the laravel cache manager system</p>
  
  <p>any solution or any way to detect what's under the hood.</p>
  
  <p>thanks in advance</p>
  
  <p><strong>Edit</strong></p>
  
  <p>css and javascript files are loading and any images from mywebsite.com/img , but images from a different location doesn't load, I checked the location block to see if it match for all images and it worked well </p>