I need a quick tip on something which seems really simple. I have some pictures inside private folder and would like to display them inside my View.
The only solution I found was this:
def show
send_file 'some/image/url', :disposition => 'inline', :type => 'image/jpg', :x_sendfile => true
end
I've read that :disposition => 'inline'
should not trigger image download and allow me to display it inside my View. The problem is that each time I trigger show
action, image download is automatically activated and it is automatically downloaded. View for show
action is not displayed.
How can I display that image inside my View? Thank you.