mardi 22 septembre 2015

How to display multiple images from the database in html.erb?

So basically what I would like is to know what the ruby code is to display an image from the database. Here's an example. Let's say I want to see product id:1's page - it should display the designated image correlated with that id number. Now if I want id:2 it should display that image that correlates with that number. All of this will be on a single show.html.erb page. I am lost, please help.

Thanks!

Aucun commentaire:

Enregistrer un commentaire