lib/tiny_forms.rb
# Generic builder template for a field in which the label appears first
Generic builder template for a field in which the label appears first
Generic builder template for a field in which the label appears first
def select(field, choices, options = {}, html_options = {})
      content = eval(BUILDER_FIELD)
      klass = "select"
      klass << " required" if options[:required]
      @template.content_tag(options[:tag] || 'p', content, :class=>klass, :id => "p_#{@object_name}_#{field}")
    end
def select ( field , choices , options = { } , html_options = { } ) content = eval ( BUILDER_FIELD ) klass = "select" klass << " required" if options [ :required ] @template . content_tag ( options [ :tag ] || 'p' , content , :class => klass , :id => "p_#{@object_name}_#{field}" ) end
Generic builder template for a field in which the label appears first
Generic builder template for a field in which the label appears first
field
<not_specific>
choices
<not_specific>
options
<not_specific>
html_options
<not_specific>