I am using Laravel 5.2.  

How to control file's opening and downloading?  

Like this: 

```
xxx.php?filename=0001.jpg 

```

Sometimes browser will show the image ,and sometimes will show a file download box ?How to control it?