KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
To get the image path in Controller I use the following method: class AssetsController < ApplicationController def download(image_file_name) path = Rails.root.join("public", "images", image_file_name).to_s send_file(path, ...) end end Is there a better method to find the path ?
Tags (comma-separated)
Save Edits
Cancel