Skip to content

Instantly share code, notes, and snippets.

@rhizome
Created June 30, 2012 19:57
Show Gist options
  • Save rhizome/3025284 to your computer and use it in GitHub Desktop.
Save rhizome/3025284 to your computer and use it in GitHub Desktop.
<%= content_tag :li, link_to_unless_current( "#{cat.titleize}", polymorphic_path([@user,cat.to_sym]) ) {
link_to("#{cat.titleize}", polymorphic_path([@user,cat.to_sym])) }, :class=>(controller_name.to_s == cat.to_s && action_name == "index") && "current"
-%>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment