Sha256: 7c7d9113bf5ca7602c783a30b909c9352dace5e9bfa54f896619d9c46c6d8b53
Contents?: true
Size: 701 Bytes
Versions: 2
Compression:
Stored size: 701 Bytes
Contents
# anti-spam This gem implements a simple anti-spam on Rails projects based on [David Walsh's solution](http://davidwalsh.name/wordpress-comment-spam). Basically, it stops spam comming from bots that doesn't execute JavaScript (most of them), or only execute the page load JavaScript. First, include this gem on your Gemfile: gem 'anti_spam' Add it to your javascript file, usually application.js //= require anti-spam Then add the protect\_from\_spam filter on the desired actions before_action :protect_from_spam, only: [:create, :update] That's it! Be aware that users without JavaScript will be considered bots, but nowadays that's very rare, chances are that it's really a bot.
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
anti_spam-0.0.2 | README.md |
anti_spam-0.0.1 | README.md |