public Method

RecordTagHelper.div_for(record, *args, &block)

Produces a wrapper DIV element with id and class parameters that relate to the specified ActiveRecord object. Usage example:

<% div_for(@person, :class => "foo") do %>
   <%=h @person.name %>
<% end %>

produces:

<div> Joe Bloggs </div>

Source Code

# File action_view/helpers/record_tag_helper.rb, line 15
def div_for(record, *args, &block)
  content_tag_for(:div, record, *args, &block)
end
Comments

Have your say
Please use Textile formatting (click here for a cheat sheet). Use <code/> and <pre/> for code samples.
Click here to login with OpenID to to post comments.