thank you, it worked
On Wednesday, August 17, 2011, Robert Walker
<lists-fsXkhYbjdPsEEoCn2XhGlw@public.gmane.org>
wrote:> Rodrigo Ruiz wrote in post #1017036:
>> If anyone can help me please do.
>
> I''m guessing about the meaning of your question, which is oddly in
the
> subject of this post rather than the body of the post, but I assume you
> mean to say that you have a text area where the visitor can type
> multiple lines of text that gets stored into the database with
> appropriate new line (i.e. \n) characters.
>
> It''s not that the new line characters are not "saved" as
you phrased it,
> but rather that HTML treats all whitespace (i.e. Space, Tab, Carriage
> Return, Line Feed, etc.) as a single space character.
>
> This simplest solution is to replace LF (or CRLF) characters with the
> HTML <br /> tag. Fortunately Rails provides a view helper for this
> purpose called simple_format:
>
>
http://api.rubyonrails.org/classes/ActionView/Helpers/TextHelper.html#method-i-simple_format
>
> --
> 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-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
> To unsubscribe from this group, send email to
rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
> For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en.
>
>
--
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-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en.