Skip to content

Commit

Permalink
Updated documentation for installation
Browse files Browse the repository at this point in the history
  • Loading branch information
tractorcow committed Feb 11, 2014
1 parent d25dad0 commit 1593376
Showing 1 changed file with 38 additions and 19 deletions.
57 changes: 38 additions & 19 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,30 +14,49 @@
* Silverstripe SpamProtection module
* Mollom REST PHP Client <https://github.com/Mollom/MollomPHP>

## Documentation
## Installation

Extract all files into the 'mollom' folder under your Silverstripe root, or install using composer

```bash
composer require silverstripe/mollom dev-master
```

If the mollom module causes an error in composer it may be necessary to explicitly add the
git url to your composer.json

*composer.json*

```json
{
"repositories": [
{
"type": "git",
"url": "https://github.com/Mollom/MollomPHP.git"
}
]
}
```

## Configuration

This module provides a FormField and SpamProtector classes for integration with
the SpamProtection module in SilverStripe. Consult that module documentation for
more information on how to setup and enable Mollom on your Forms.

To configure the use of this protector, use the Config API.

*mysite/_config/spamprotection.yml*
---
name: spamprotection
---
FormSpamProtection:
default_spam_protector: MollomSpamProtector

You will also need to sign up to [Mollom](http://mollom.com) to get API keys for
To configure the use of this protector, use the Config API. You will also
need to sign up to [Mollom](http://mollom.com) to get API keys for
the website. Those should also been included through the Config API

*mysite/_config/spamprotection.yml*
---
name: spamprotection
---
FormSpamProtection:
default_spam_protector: MollomSpamProtector
Mollom:
public_key: <key>
private_key: <key>

```yaml
---
name: spamprotection
---
FormSpamProtection:
default_spam_protector: MollomSpamProtector
Mollom:
public_key: <key>
private_key: <key>
```

0 comments on commit 1593376

Please sign in to comment.