Displaying 2 results from an estimated 2 matches for "sanitized_allowed_tags".
2009 Jan 24
1
Rails sanitize method is stripping my anchors
...hod to clean
the html before output. The problem is that it is stripping my anchors.
e.g: <h2 id=''team''>Our Team</h2> becomes <h2>Our Team</h2>
How can I prevent sanitize from stripping the anchors? I have added "h2
id'' to config.action_view.sanitized_allowed_tags but it did not work.
--
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-/JYPxA39Uh5TL...
2008 Oct 18
2
Sanitize add more tags
I have added the following snippet to environment.rb:
Rails::Initializer.run do |config|
config.action_view.sanitized_allowed_tags = ''table'', ''tr'', ''td'', ''th''
end
But it doesn''t work, my tags still get removed. Any idea why it is
happening?
--
Posted via http://www.ruby-forum.com/.
--~--~---------~--~----~------------~-------~--~----~
You recei...