I have completed first two steps in ‘Show a Tag’ section. But when I try to evaluate 3rd step, it is showing error message. ‘Unknown attribute tag_id’.
Here is my code for show.html.erb
<img src="http://s3.amazonaws.com/codecademy-content/courses/learn-rails/img/logo-1tm.svg" width="80">
<div class="cards row">
<%=@destinations.each do |d| %>
<div class="card col-xs-4">
Can we have the code for
I have updated my question. Please have a look.
Should be like this
<%= d.image %>
We won’t need to use
img tag in this case.
That did n’t help. It is still reporting same error. Btw, why don’t we need img tag in this case? Image location is stored as string. How rails will interpret it as an image?
<%= image_tag d.image %>
is how the line should be.
image_tag is a built in thing that comes with Rails.
2 posts were split to a new topic: What i do wrong here?
A post was merged into an existing topic: What i do wrong here?