I would like to combine 2 commands into 1, if its possible.
<%= render :partial => 'shared/logo' %>
<%= link开发者_开发问答_to 'Dashboard', root_url %>
I would like to call the logo in the shared directory and have it be a link at the same time.
How would I write this?
This should do it:
<%= link_to render(:partial => 'shared/logo'), root_url %>
精彩评论