Silverstripe: How can I disable comments?
- by SamIAm
My client site is built in Silverstripe, there is a news page, and it allows people to leave comments. Unfortunately we've got loads of spam emails. I'm new to this, is there any way we can disable the comment field by default? How do I do it? Alternatively is there easy way for me to install a spam protection?
Update - Because this is someone else's code, I just realised that they have some sort of spam protection already, so we are trying to disable comments now. I have manage to set no comment as default by changing file BlogEntry.php
static $defaults = array(
"ProvideComments" => true,
'ShowInMenus' => false
);
to
static $defaults = array(
"ProvideComments" => false, //changed
'ShowInMenus' => false
);
Am I on the right track to disable comments by default? Also how can I stop on the news page showing xxx comments link? eg
Test
Posted by Admin on 21 June 2011 | 3 Comments
Tags: P
This is a test....
3 comments | Read the full post