Download the PHP package eo/honeypot-bundle without Composer
On this page you can find all versions of the php package eo/honeypot-bundle. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package honeypot-bundle
EoHoneypotBundle
Honeypot for Symfony2 forms.
What is Honey pot?
A honey pot trap involves creating a form with an extra field that is hidden to human visitors but readable by robots. The robot fills out the invisible field and submits the form, leaving you to simply ignore their spammy submission or blacklist their IP. It’s a very simple concept that can be implemented in a few minutes and it just works – add them to your contact and submission forms to help reduce spam.
Prerequisites
This version of the bundle requires Symfony 2.1+
Installation
Step 1: Download EoHoneypotBundle using Composer
Add EoHoneypotBundle to your project by running the command:
Composer will install the bundle to your project's vendor/eo
directory.
Step 2: Enable the bundle
If you use Symfony Flex - skip this step. Otherwise, enable the bundle in bundles.php
:
Step 3 (optional): Configure bundle to use database
To save honeypot catched requests into database you have to enable it in your configuration file: All parameters are optional
If you enable the database storage, you must create a class which extends
the Eo\HoneypotBundle\<Entity|Document>\HoneypotPrey
base class :
or
Usage
Once installed and configured you can start using Eo\HoneypotBundle\Form\Type\HoneypotType
form type in your forms.
Basic usage example:
Events
If the hidden honeypot field has some data bundle will dispatch a bird.in.cage
event. You can create an event listener to execute custom actions. See Eo\HoneypotBundle\Event\BirdInCage and How to Register Event Listeners and Subscribers for more information.
License
This bundle is under the MIT license. See the complete license in the bundle:
Reporting an issue or a feature request
Issues and feature requests related to this bundle are tracked in the Github issue tracker https://github.com/eymengunay/EoHoneypotBundle/issues.