Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- module ApplicationHelper
- def render_site_menu(menu= :site_menu, project=nil)
- links = []
- menu_items_for(menu, project) do |item, caption, url, selected|
- links << content_tag('li',
- link_to(h(caption), url), item.html_options(:selected => selected))
- end
- links.empty? ? nil : content_tag('ul', links.join("\n"))
- end
- end
Add Comment
Please, Sign In to add comment