# File lib/action_view/helpers/javascript_helper.rb, line 112 def button_to_function(name, *args, &block) html_options = args.extract_options!.symbolize_keys function = args[0] || '' function = update_page(&block) if block_given? tag(:input, html_options.merge({ :type => "button", :value => name, :onclick => (html_options[:onclick] ? "#{html_options[:onclick]}; " : "") + "#{function};" })) end