Andrew Bloom wrote:

> def current_li(content, x)
>   klass = x ? "current" : nil
>   content_tag(:li, content, :class => klass)
> end
> 

Thanks, but why this doesn't work?

<%= current_li {link_to "xxx", :controller => "yyy"}, @x == 1 %>
-- 
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 [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
-~----------~----~----~----~------~----~------~--~---

Reply via email to