On Thu, Oct 2, 2008 at 11:00 AM, Pardee, Roy <[EMAIL PROTECTED]> wrote: > > This is arguably a tad bit prettier: > > title.downcase.gsub(/[^a-z ]/, '').gsub(/ /, '-')
..but doesn't do the same thing as the OP's -- this one will strip out non-vanilla-ASCII accented characters, which could well be part of a title. Not all books are written in America :-) -- Hassan Schroeder ------------------------ [EMAIL PROTECTED] --~--~---------~--~----~------------~-------~--~----~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---