kreativmonkey Posted March 26, 2016 Share Posted March 26, 2016 Hi Guys, since i start with Processwire last year, i miss a module for filter Spam at the comment field without any external service. I know about a good module from the time i use Wordpress. Now i have move the most part of the module to work on Processwire. I have write about the Module idea previously: https://processwire.com/talk/topic/10028-comment-spamprotection-without-akismat/#entry116684 And now there is a first alpha on Github: https://github.com/kreativmonkey/antispam-guard Actually functions: Check bbcode Check regexe Check if the commenter is knowen as approved or spam Check the IP is no fake Automatically approve ore pending no spam comments Automatically approve trusted commenter Automatically mark spam Check Gravatar Check external Spamdb Future: Local spam IP database Add Honeypot to Commentform Only permit certain languages Testing For testing the module you need some Modification to the FieldtypeComments.module : if($field->useAkismet) { $akismet = $this->modules->get('CommentFilterAkismet'); $akismet->setComment($comment); $akismet->checkSpam(); // automatically sets status if spam } else { $comment->status = Comment::statusPending; } if($field->useAntispamguard) { $antispam = $this->modules->get('CommentFilterAntispamguard'); $antispam->setComment($comment); $antispam->checkSpam(); // automatically sets status if spam } else { $comment->status = Comment::statusPending; } Now you place the CommentFilterAntispamguard.module and CommentFilterAntispamguardConfig.php in the same Folder as FieldtypeComments.module and activate it in the Processwire Module admin section. At the last step go to you comment field -> options and activate "Use Antispamguard". I am pleased with your feedback and suggestions for improvement 6 Link to comment Share on other sites More sharing options...
LostKobrakai Posted March 26, 2016 Share Posted March 26, 2016 The second change could easily be made by a hook to FieldtypeComments::getConfigInputfields, where $event->return is the form you can edit. $f->insertAfter() will make this really easy to add in. 2 Link to comment Share on other sites More sharing options...
kreativmonkey Posted March 27, 2016 Author Share Posted March 27, 2016 The second change could easily be made by a hook to FieldtypeComments::getConfigInputfields, where $event->return is the form you can edit. $f->insertAfter() will make this really easy to add in. Thank you for the hint. I updated the Module and use the hook. Is it possible that the Plugin now must be "Autoload"? Link to comment Share on other sites More sharing options...
LostKobrakai Posted March 27, 2016 Share Posted March 27, 2016 Yeah. But there are way to let autoloading be determined conditionally, but I haven't used them by now. Link to comment Share on other sites More sharing options...
neophron Posted May 25, 2019 Share Posted May 25, 2019 Hi, I launched a site with comments functions. Now the website is online and I totally forgot about the missing honeypot option in the comment form. Are there, besides the Akismet option, other possibilities for spam fighting? The module here is 3 years old and there is a warning: Do not use yet!!! Is this still the only solution? Link to comment Share on other sites More sharing options...
Robin S Posted May 25, 2019 Share Posted May 25, 2019 1 hour ago, neophron said: I totally forgot about the missing honeypot option in the comment form. There is a honeypot option. There's a JS-based approach that goes back a long time... ...and a more recent addition... https://github.com/processwire/processwire/commit/8405c586f03a2a0a6271b5edd5ba9361f768da6a 1 Link to comment Share on other sites More sharing options...
neophron Posted May 25, 2019 Share Posted May 25, 2019 Thanks for these informations. I'll have a closer look at this next week. Link to comment Share on other sites More sharing options...
gr00__ Posted July 8, 2019 Share Posted July 8, 2019 EDIT: can't delete post, but I need to check more... there was some error on my end. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now