Use render_to_string(options = nil, &block) and use the send_data
API.
On Jan 8, 7:27 am, Raj
<neeraj....-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
wrote:> I need to provide users a link to download an user_guide.txt file.
>
> Currently the user_guide.html.erb looks like this.
>
> Dear <%...@user.name %>,
>
> Please visit <%=@unlocking_webiste %> site.
>
> ...
> ...
>
> the point is that the file has some variables which needs to be
> replaced then user should be able to download these files and use
> them.
>
> I can find ways to download a static file but in this case how should
> I code such that users are able to download the customized files.
>
> Thanks
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Ruby on Rails: Talk" group.
To post to this group, send email to
rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk+unsubscribe@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---