see ActionView::Helpers::TextHelper#strip_tags
Will Gant wrote:> Hello all,
> I''m working on a bit of code that needs to convert HTML to plain
text.
> Is there an easy way to do this in Ruby, or do I need to write some
> code to handle it with a regular expression? I only want the
> human-readable parts of the page, so I also have to remove anything
> within script tags.
>
> Thanks,
> Will
>
>
> Yes, even I blog now:
>
> http://willsmentaldebris.blogspot.com/
>
> ------------------------------------------------------------------------
> Got a little couch potato?
> Check out fun summer activities for kids.
>
<http://us.rd.yahoo.com/evt=48248/*http://search.yahoo.com/search?fr=oni_on_mail&p=summer+activities+for+kids&cs=bz>
> >
--
Sincerely,
William Pratt
--~--~---------~--~----~------------~-------~--~----~
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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---