It might be the syntax you’re using. Try using the :locals argument:
@m = render_to_string :template => "template", :locals => {:sender => sender}
Then you just need to access sender (without an @) as a local variable inside the template.
It might be the syntax you’re using. Try using the :locals argument:
@m = render_to_string :template => "template", :locals => {:sender => sender}
Then you just need to access sender (without an @) as a local variable inside the template.