Need help iterating over attributes of a Active record object

Hi all...

I need help with a little ruby code. I am trying to output every
attribute of an actice record object something like:

<% for product in @products %>
    <% for each product.attribute |attribute| %>
    <% end %>
<% end %>

product.attributes return a Hash object, so you want:

<% product.attributes.each_pair do |k,v| %>
  <li><%= k %> => <%= v %></li>
<% end %>

Thanks alot mate...