No commit activity in last 3 years
No release in over 3 years
Sanitizes your ActiveRecord attributes.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

Runtime

>= 3.2
 Project Readme

Acts As HTML Sanitized

Gem Version Build Status Code Climate Coverage Status

...and I hope you've learned to sanitize your database inputs

Sanitize your database inputs!

Requirements

Ruby and Rails

Acts As HTML Sanitized requires Ruby version >= 1.9.3 and Rails version >= 3.2. That's it.

Installation

Acts As HTML Sanitized is distributed as a gem, which is how it should be used in your app.

gem 'acts_as_html_sanitized'

Quick Start

Models

class User < ActiveRecord::Base
  acts_as_html_sanitized
end

This will cause the content of any attribute in the User model being stripped of HTML prior to being validated.

Contributing

If you'd like to contribute a feature or bugfix: Thanks! To make sure your fix/feature has a high chance of being included, please read the following guidelines:

  1. Post a pull request.
  2. Make sure there are tests! We will not accept any patch that is not tested. It's a rare time when explicit tests aren't needed. If you have questions about writing tests for paperclip, please open a GitHub issue.

Please see CONTRIBUTING.md for more details on contributing and running tests.

License

Acts As HTML Sanitized is Copyright © 2014 Sasha Gerrand. It is free software, and may be redistributed under the terms specified in the MIT-LICENSE file.