File download in Rails

I've got problem with allow user to download file.

This is sending method:

class DownloadController < ApplicationController
def send
    @headers["Content-Type"] =
    send_file(("./public/files/"+params[:path]+"/"+params[:name]), :type =>

In view i have:

<%= link_to st, :controller => "download", :action => "send", :path => s,
:name => st %>

I get error:

Status: 500 Internal Server Error Content-Type: text/html 500 Internal
Server Error


My own blog (in polish) :