link_helper.rb revision d0da511991743a77c38f34c6febcbaff007b5e9b
text << content_tag
(:span, counter==1 ? subject : subject.pluralize)
def format_links(*args, &block)
options = args.extract_options!
args = %w(xml json) if args.empty?
links << capture(&block) << ' ' if block_given?
links << args.collect{ |f|
content_tag :li, link_to(f.to_s.upcase, params.merge(options[:url]).merge(:format => f), :title => "Get this page as #{f.upcase}")
content_tag('ul', links.html_safe, :class => 'formats')