Helper within a Helper? (IMAGE PLACEMENT)

I would like to call an image to be displayed based on its title. It is
easy enough for me to do this like this:

But I want to stick within the ruby code and I’m trying this:

<%= image_tag("/images/suggested/<%= suggested.title %>", size=>
“100x100”) %>

but its not working.

Anything i’m missing? Any better alternatives?



<%= image_tag("/images/suggested/#{suggested.title}", size=>
“100x100”) %>

will work

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs