Comments (7)
Are you running the latest master checkout?
from silverstripe-comments.
No i'm running V1.1 as its a SS 3.0 installation.
Not sure if its related but when I go to mark a comment as spam. I receive this error:
[Notice] Undefined variable: request
GET /site/CommentingController/spam/17?SecurityID=f94b6e96687a8cb2a820d6f61ac717af7a0b4868
Line 136 in /home/ccremove/public_html/site/comments/code/controllers/CommentingController.php
relating to this peice of code:
public function spam() {
136 if(!$this->checkSecurityToken($request)) {
137 return $this->httpError(400);
138 }
from silverstripe-comments.
Is there any updates on this at all? Perhaps I have something set wrong?
from silverstripe-comments.
Not sure whether anyone has had a look into this, perhaps I wasn't understanding how moderation works.
I have 'require_moderation' set to true in /mysite/_config.php
Commenting::add('Foo', array(
'require_moderation' => true
));
However when I add a comment it is still displaying in the Moderated tab in the backend. Editing the comment through the backend I can see the the 'Moderated?' checkbox is checked. I assume this shouldn't be the case.
I'm not sure what the 'Foo' section means. I understand that this is the name of the array (at least I hope im right here). Do I need to use this 'Foo' name elsewhere in my code. There doesn't seem to be much documentation on this.
from silverstripe-comments.
After a bit more digging in I realised I needed to do the following into the /mysite/_config.php
Commenting::set_config_value('SiteTree', 'require_moderation',true);
No in the backend of the site new comments are not moderated. The issue I have now is that they still show up on the website. I presume its this code in the CommentingController.php that assigns whether to display it or not, but its doesn't seem to affect it
if(!$comment->Moderated) {
echo $comment->renderWith('CommentInterface_pendingcomment');
} else {
echo $comment->renderWith('CommentInterface_singlecomment');
}
from silverstripe-comments.
I amended the CommentsInterface.ss template to check for moderation. Works for me.
<% loop Comments %>
<% if Moderated %>
<li class="comment $EvenOdd<% if FirstLast %> $FirstLast <% end_if %> $SpamClass">
<% include CommentsInterface_singlecomment %>
</li>
<% end_if %>
<% end_loop %>
from silverstripe-comments.
Request var has been fixed, Comments are filtered by Moderated status and test added for that behaviour (5a8de05).
from silverstripe-comments.
Related Issues (20)
- "RSS feed for comments on this page" doesn't work for blog posts
- Have the JS URL validator validate valid URLs HOT 4
- Content is saved plaintext into cookies. HOT 1
- 'use_preview' => true - doesn't seem to work HOT 3
- frontend_moderation: false doesn't seem to do anything HOT 1
- Clicking "select" checkbox in Comments GridField takes you immediately to GridField edit form HOT 1
- Showing comments from another Page HOT 1
- BUG CommentAdmin permission not available in Permissions tab HOT 3
- RSS feed for pre-SS4 comments doesn't work for blog posts HOT 1
- Docs missing information about $CommentsForm Tag HOT 3
- action checkboxes broken HOT 2
- CommentsExtension->canPost is deprecated HOT 2
- jQuery validation shows required to non-required fields
- Comments UI needs a refresh
- CommentAdmin layout is broken
- Comment 'Name' and 'Email can be manipulated even if CommentsRequireLogin is true
- Trying to get in touch regarding a security issue HOT 2
- Can't install on SS4.9 HOT 1
- Can't display $CommentsForm for DataObjects HOT 1
- Only user with full admin right can comment HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from silverstripe-comments.