Method: ActionView::Helpers::SanitizeHelper::ClassMethods#sanitized_uri_attributes=

Defined in:
actionpack/lib/action_view/helpers/sanitize_helper.rb

#sanitized_uri_attributes=(attributes) ⇒ Object

Adds valid HTML attributes that the sanitize helper checks for URIs.

class Application < Rails::Application
  config.action_view.sanitized_uri_attributes = 'lowsrc', 'target'
end

183
184
185
# File 'actionpack/lib/action_view/helpers/sanitize_helper.rb', line 183

def sanitized_uri_attributes=(attributes)
  HTML::WhiteListSanitizer.uri_attributes.merge(attributes)
end