Where can I find more information about the new syntax on these:
<%- model_class = @product.class -%>
<h1><%=t '.title', :default => t('helpers.titles.new', :model =>
model_class.model_name.human,
:default => "New
#{model_class.model_name.human}") %></h1>
<%= render :partial => 'form' %>
I've been using rails for a little bit and the "model_class = ..." is all
new to me, plus I can't make sense of this:
<%=t '.title', :default => t('helpers.titles.new', :model =>
model_class.model_name.human, :default => "New
#{model_class.model_name.human}") %>
Thanks!
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To view this discussion on the web visit
https://groups.google.com/d/msg/rubyonrails-talk/-/eGAp5qbZVWYJ.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en.