Rails 关于 send_file,求帮助

roam · January 24, 2013 · Last by Roam replied at January 24, 2013 · 2923 hits

我用的是 nginx,在做 Download 的时候,send_file 不 work

在 google network 脚本中是这样的

Cache-Control:private Connection:keep-alive Content-Disposition:inline; filename="test.xls" Content-Transfer-Encoding:binary Content-Type:application/xls Date:Thu, 24 Jan 2013 04:48:51 GMT Server:nginx/1.2.6 Transfer-Encoding:chunked X-Request-Id:57c48c7050112100289d8345f48d5af8 X-Runtime:0.106000 X-UA-Compatible:IE=Edge

Controller 是 send_file( filename)

为什么下载不了呢?大大们帮帮忙

nginx 里 sendfile on; 开了没

You need to Sign in before reply, if you don't have an account, please Sign up first.