SpringFlowers AutumnMoon wrote: > i think to_json is more like a transition to the Javascript realm... > however, isn't it true that if we ever need to set the title into the > div's innerHTML, then we also need to sanitize it? > > so to_json(h(title)) ?
and is there something like to_json(strip_tags(title)) ? i think this one always works and just remove any tag from the title. -- 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---