I am new to this whole Haml thing as of last night and am very
impressed. I tried switching over a simple .erb template to .haml and
having a problem. I am guessing I didn't properly Haml the section
below my / note. I have tried a few things but no luck. So, can anyone
tell me what is wrong with the following? (this is all the code in my
partial named /contacts/_contact.html.haml


%table

  %tr
    %th avatar
    %th contact name
    %th city
    %th email
    %th mobile
    %th phone
    %th company name
    %th action(s)

    / this and probably the remainin lines still need proper Haml
markup. I am not doing something rite
    <% @contacts.each do |contact| %>

  %tr
    %th <%= image_tag contact.avatar, :class => 'img_avatar_thumb' %>
    %th <%= contact.first_name %> <%= contact.last_name %>
    %th <%= contact.city %>
    %th <%= contact.email %>
    %th <%= if !contact.mobile.blank? %><
%=number_to_phone(contact.mobile, :area_code => true)%> <% end %>
    %th <%= if !contact.phone.blank? %><
%=number_to_phone(contact.phone, :area_code => true)%> <% end %>
    %th <%= contact.company_name %>
    %th <%= link_to image_tag("/images/buttons/
ico_buscard.png", :alt=>"Show contact card"), contact %> <%= link_to
image_tag("/images/buttons/ico_edit.png", :alt=>"Edit contact"),
edit_contact_path(contact) %> <%= link_to image_tag("/images/buttons/
ico_delete.png", :alt=>"Delete contact"), contact, :confirm => 'Are
you sure?', :method => :delete %>
<% end %>

-- 
You received this message because you are subscribed to the Google Groups 
"Haml" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to [email protected].
For more options, visit this group at http://groups.google.com/group/haml?hl=en.

Reply via email to