How to load a html.haml file from a custom class, store in a var its data, then apply some instance variables and render it in the view?
A:
Your description of the problem is light on details, but I think your HAML file should be a partial, and you can just use
render :partial => "<your file name>", :locals => {:foo => 'bar'}
in your view, and pass the variables you want via :locals.
There is a description of working with partials in this guide.
Alex - Aotea Studios
2010-05-13 21:06:04