module ActionView::Helpers::FormHelper
def form_for_with_haml(object_name, *args, &proc)
def form_for_with_haml(object_name, *args, &proc) if block_given? && is_haml? oldproc = proc proc = proc {|*args| with_tabs(1) {oldproc.call(*args)}} end res = form_for_without_haml(object_name, *args, &proc) res << "\n" if block_given? && is_haml? res end
def form_for_with_haml(object_name, *args, &proc)
def form_for_with_haml(object_name, *args, &proc) if block_given? && is_haml? oldproc = proc proc = haml_bind_proc do |*args| tab_up oldproc.call(*args) tab_down concat haml_indent end concat haml_indent end form_for_without_haml(object_name, *args, &proc) concat "\n" if block_given? && is_haml? Haml::Helpers::ErrorReturn.new("form_for") if is_haml? end
def form_for_with_haml_xss(*args, &block)
def form_for_with_haml_xss(*args, &block) res = form_for_without_haml_xss(*args, &block) return Haml::Util.html_safe(res) if res.is_a?(String) return res end