title: Force browser to download image file from external server in laravel
body: <p>Images in my project are from an external server; I want to download them when click on download button or  tag, but open them in another page.</p>
  
  <pre><code>                @foreach($items as $item)
                  &lt;div class="col-lg-2 col-md-4 col-sm-6 nopad image-gallery"&gt;
                      &lt;a target="_blank" class="fancybox mediaReportItem persianNum downloadImg" rel="fancybox-button"
                         downloadpath="{{ $mediaAddress. '/' .$item-&gt;image-&gt;original_path }}" id="{{ $item-&gt;id }}"
                         href="{{ $mediaAddress. '/' .$item-&gt;image-&gt;original_path }}" title="{{ $item-&gt;title }}"&gt;
                          &lt;img src="{{ $mediaAddress. '/' .$item-&gt;image-&gt;thumb_path }}" class="photoThumbnaill"
                               alt="{{ $item-&gt;title }}" download&gt;&lt;/a&gt;
                  &lt;/div&gt;
              @endforeach
  </code></pre>
  
  <p>And download not work Because image is on external server.</p>
  
  <pre><code>response()-&gt;download($file);
  </code></pre>