Laravel 5: Download file not show popup for save
<p>In my Laravel 5.3, I uploaded file to "uploads/files/file.pdf". When I try to download it, the file is found using "file_exists" function but there is no popup window to save the file into the local computer. Note: I removed "public" folder from url by moving files to sub-directory called "local".</p>

<p>Please advice what is wrong.</p>

<pre><code>namespace App\Http\Controllers;

use Auth;
use Illuminate\Http\Request;
use App\Http\Requests;
use Response;

...............................

public function getDownload()
{
    $file= "uploads/files/file.pdf";

    echo $file;

    if(file_exists($file)){
        dd('File is exists.');
    }else{
        dd('File is not exists.');
    }        

    $headers = array('Content-Type: application/pdf',);
    return Response::download($file, 'filename.pdf', $headers);
}
</code></pre>