Advertisement
Guest User

Untitled

a guest
May 5th, 2015
187
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.47 KB | None | 0 0
  1. <VirtualHost *:80>
  2. DocumentRoot /var/www/html/public
  3. <Directory "/var/www/html">
  4. Options Indexes MultiViews FollowSymLinks
  5. AllowOverride All
  6. </Directory>
  7. XSendFile On
  8. XSendFilePath /var/www/html/public
  9.  
  10. ErrorLog ${APACHE_LOG_DIR}/error.log
  11. CustomLog ${APACHE_LOG_DIR}/access.log combined
  12. </VirtualHost>
  13.  
  14. header("X-Sendfile: $file->path");
  15. header("Content-Type: application/octet-stream");
  16. header("Content-Disposition: attachment; filename="$file->name"");
  17. exit;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement