I fixed the issue, it was related to override of name attribute in the
model class.
--
Posted via http://www.ruby-forum.com/.
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googleg
Try to be more specific with old versions of Rails and change
<%= render(@locations) %>
to
<%= render :partial => "location/location", :collection => @locations
%>
In this case _location partial should have local variable "location"
correctly set.
Hope, this helps.
MaxR
>
> Colin, I already trie
Colin Law wrote in post #1064039:
> On 11 June 2012 14:58, Jamal Soueidan wrote:
>> locations/location.html.erb
>>
>> <%=location.name%>
>> <%=location.name%><%=location.name%><%=location.name%>
>>
>> name attribute only outputs one time??
>
> To work out what is going on in these situations it is
On 11 June 2012 15:16, Jamal Soueidan wrote:
> Colin, I already tried that
>
> It's only outputting A and nothing else.
>
> but if I change to.
>
> <% @locations.each do |location| %>
> A <%=location.name%> B
> <%=location.name%> C <%=location.name%> D <%=location.name%> E
> <% end %>
>
> it work
Colin, I already tried that
It's only outputting A and nothing else.
but if I change to.
<% @locations.each do |location| %>
A <%=location.name%> B
<%=location.name%> C <%=location.name%> D <%=location.name%> E
<% end %>
it works.
--
Posted via http://www.ruby-forum.com/.
--
You received
5 matches
Mail list logo