Ruby on Rails
Thursday, July 26, 2012
How about wrap content in "<pre></pre>"??
On Friday, July 27, 2012 2:16:44 AM UTC+8, Ruby-Forum.com User wrote:
Currently I am using--
<%= File.read('/path/to/file.txt') %>
to render my file on the screen, but this puts the whole file in one
line. How would I output the file on the screen the way it is saved in
the .txt document? (I can't use render_file)
--
Posted via http://www.ruby-forum.com/.
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@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msg/rubyonrails-talk/-/-u3Yr9XY3A4J.
For more options, visit https://groups.google.com/groups/opt_out.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment