MINOR: how to add spam control
This commit is contained in:
parent
7e202debb7
commit
a650b95a28
|
@ -75,6 +75,20 @@ use SilverStripe\CMS\Model\SiteTree;
|
|||
// Get the setting
|
||||
$loginRequired = singleton(SiteTree::class)->getCommentsOption('require_login');
|
||||
```
|
||||
### spam control
|
||||
|
||||
you can create a comment.yml file with the following content:
|
||||
|
||||
```yml
|
||||
---
|
||||
Name: 'app_comments_spam'
|
||||
---
|
||||
|
||||
SilverStripe\Comments\Forms\CommentForm:
|
||||
extensions:
|
||||
- SilverStripe\SpamProtection\Extension\CommentSpamProtection
|
||||
```
|
||||
|
||||
|
||||
|
||||
## HTML Comments
|
||||
|
|
Loading…
Reference in New Issue