Topic: Calling partial of another view
Hello,
I am very new to ruby on rails and I am facing little problem with
image_tag.
I have two controller product and items. In product view, I have a
partial called _show.html.erb. And in items view, i call index of item
to display all products. The problem is, when user clicks on the
image_tag of the items view, i want to call partial of product view i.e
_show.html.erb.
here is the view code:
<%@products.each do |product|%>
<div class="entry">
<%=link_to image_tag(product.image_url)%> #"I want to call a partial here"
<h3><%= product.name%></h3>
</div>
<%end%>
Please help me
thanks,
Mohan
Last edited by MohanatRails (2012-04-23 12:50:19)