Hi,
I'm having trouble getting send_file to work.  I'm building a relatively
small csv file, and trying to let the user download it.

My action to do the download looks like this:

  def send_the_file
    @temp_download_file_path = session[:temp_file_path]
    send_file @temp_download_file_path,
                     :x_sendfile => true,
                     :type => 'text/csv',
                     :filename => "contacts.csv"
  end

No errors are generated.  Log says it is sending it.  I wind up with an
empty ( 1
byte) file on the other end.  I get the same results with and without
the "x_sendfile".

Any advice on where the file should reside on my server and how to set
the necessary permissions to allow send_file to get at it?  What else
could I be doing wrong?

Thanks for any additional help you guys can provide.

jp
-- 
Posted via http://www.ruby-forum.com/.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to