Custom configuration

locojohn nginx-forum at nginx.us
Wed Mar 28 18:31:19 UTC 2012


Adnan,

For the following to work you need headers module installed:

               location ~ /(?<filename>(?!/).+\.mp3)$ {
                  types {
                    application/octet-stream mp3;
                  }
                  add_header Content-Disposition "attachment;
filename=\"$filename\"";
                }

Kind regards,

Andrejs

Posted at Nginx Forum: http://forum.nginx.org/read.php?2,224499,224577#msg-224577



More information about the nginx mailing list