Sha256: f9f89803e8380888e5f1c75a071c7b6f1baf514a7ae48cc0bde7493d426598e2

Contents?: true

Size: 1.36 KB

Versions: 3

Compression:

Stored size: 1.36 KB

Contents

<% form_for MarkupUser.new, '/demo', :id => 'demo' do |f| %>
  <%= f.error_messages(:header_message => "custom MarkupUser cannot be saved!") %>
  <p>
    <%= f.label :username, :caption => "Login", :class => 'user-label' %>
    <%= f.text_field :username, :class => 'user-text', :value => "John" %>
  </p>
  <p>
    <%= f.label :email, :caption => "Email", :class => 'user-email' %>
    <%= f.text_field :email %>
  </p>
  <p>
    <%= f.label :password %>
    <%= f.password_field :password, :class => 'user-password', :value => "secret" %>
  </p>
  <p>
    <%= f.label :photo %>
    <%= f.file_field :photo, :class => 'user-photo' %>
  </p>
  <p>
    <%= f.label :about, :caption => "About Me" %>
    <%= f.text_area :about, :class => 'user-about'  %> 
  </p>
  <p><%= f.submit "Create", :class => 'success', :id => 'demo-button' %></p>
<% end %>

<% form_for MarkupUser.new, '/another_demo', :id => 'demo2', :method => 'get' do |f| %>
  <%= f.error_messages :header_message => "custom MarkupUser cannot be saved!" %>
  <%= f.text_field_block :username, { :class => 'input' }, { :caption => 'Nickname', :class => 'label' } %>
  <%= f.password_field_block :code, { :class => 'input' } %>
  <%= f.text_area_block :about, { :class => 'textarea' } %>
  <%= f.file_field_block :photo, { :class => 'upload' } %>
  <%= f.submit_block "Create", { :class => 'button', :class => 'button' } %>
<% end %>

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
sinatra_more-0.1.9 test/fixtures/markup_app/views/form_for.erb
sinatra_more-0.1.8 test/fixtures/markup_app/views/form_for.erb
sinatra_more-0.1.7 test/fixtures/markup_app/views/form_for.erb