Hi all,
I have problem about HAML rendring
I have following small test for haml rendering
a = Coupon.first
=> #<Coupon id: 16, template_id: 1, business_id: 2, tag_line: "Tagline", expirat ion_date: "2009-07-21", disclaimer: "Disclaimer", estimated_value: #<BigDecimal: 67e1f0c,'0.123E3',4(12)>, created_at: "2009-07-22 13:56:31", updated_at: "2009-0 7-22 13:56:31", tag_line_font_style: "bold", tag_line_font_family: "Arial", tag_ line_font_size: 22, discount: "50% ", discount_font_style: "bold", discount_font _family: "Arial", discount_font_size: 22, product_or_service: "Product/Service", product_or_service_font_style: false, product_or_service_font_family: "Arial", product_or_service_font_size: 22, expiration_date_font_style: false, expiration_ date_font_family: "Arial", expiration_date_font_size: 22, text_color: "white", b ackground_color: "#201E9F">
if i give following to console
haml_engine = Haml::Engine.new("%h3 Avatar =image_tag( Photo.find(t.busines
s.avatar_id).public_filename(:thumb), :width =>'80px', :height => '80px')").rend er(Object.new, :t => a)
IT GIVES ---->
=> "<h3>Avatar =image_tag( Photo.find(t.business.avatar_id).public_filename(:th umb), :width =>'80px', :height => '80px')</h3>\n"