Hello everybody!

Im wondering what is the best way of specing action with send file
such as:

  def download
    log = ActivityLog.find(params[:id])
    if log
      send_file log.path
    else
      flash[:notice] = _("Log file \"#{params[:id]}\" was not found.")
      redirect_to :action => 'index'
    end
  end

You can see that the ActivityLog class is not inherited from AR and
the path dependes on specified ID.

Thank you in advance.

Vit
_______________________________________________
rspec-users mailing list
rspec-users@rubyforge.org
http://rubyforge.org/mailman/listinfo/rspec-users

Reply via email to