I am using Rails 2.3.5, but when I use (in HAML)
- s = render_to_string :text => "hello"
or render a partial, it says render_to_string
is not a defined method? Clearly it is in the API:
http://api.rubyonrails.org/classes/ActionController/Base.html#M000465
Right now I am using this instead:
- s = render :text => "hello"
since it is -
in front, the output is not sent to the webpage output, but render
also returns a string for s
.