pre-process real co...
 
Notifications
Clear all

Paid Addons Support Forum Only

Please note, that here we only support Paid Addons issues and questions.

gVectors Support staff works from 6am to 6pm (GMT+0)

All questions related to wpForo and wpDiscuz free plugins should be asked in the corresponding plugin support forum:

 

wpDiscuz Support Forum wpForo Support Forum

pre-process real comments


Alexey Tyazhelnikov
(@alexey-tyazhelnikov)
Member Customer
Joined: 2 months ago
Posts: 2
Topic starter  

Hello!

1) The plugin makes substitutions for obscene words.
However, the database and comments contain the original texts.
Is it possible to implement changes also in the database?

2) If you use a third-party plugin to display all the comments on one page, then it takes the data from the database and shows them in their original form without replacement.
https://wordpress.org/plugins/show-all-comments-in-one-page/

Suggest a solution, how do I pre-process before the output plugin Comment Censure.
Could you tell me what changes need to be made to the code, so that the result was pre-processed.


Quote
Astghik
(@astgh)
Support Team Admin
Joined: 4 years ago
Posts: 5048
 

Hi Alexey Tyazhelnikov,

1) The plugin makes substitutions for obscene words.
However, the database and comments contain the original texts.
Is it possible to implement changes also in the database?

We're really sorry, but we cannot change the comment content before saving it in the database. This isn't allowed.

2) If you use a third-party plugin to display all the comments on one page, then it takes the data from the database and shows them in their original form without replacement.
https://wordpress.org/plugins/show-all-comments-in-one-page/

In this case, you'll need to contact the third-part plugin with this question. The Comment Censure plugin uses the native (core) WordPress hooks and if the plugin also uses the same WordPress hooks it'll work fine. You'll need to contact the plugin support and ask them to use the comment_text hook.


ReplyQuote
Alexey Tyazhelnikov
(@alexey-tyazhelnikov)
Member Customer
Joined: 2 months ago
Posts: 2
Topic starter  

@Astghik 

1) Is there any way to move a comment containing obscene words to the status of mandatory manual moderation - or somehow disable its visibility?
even if the user is authorized and allowed to comment without pre-moderation?
make a comment with obscene words not be displayed on the site at all?

2) is it possible to initialize the functionality of Comment Censure inside code third-party plugin?
if there is any option, could you please give me an example of such code

the variant of the comment output I gave below

<blockquote><?php echo apply_filters("the_content", $comment->comment_content); ?></blockquote>

ReplyQuote
Astghik
(@astgh)
Support Team Admin
Joined: 4 years ago
Posts: 5048
 

@alexey-tyazhelnikov 

ven if the user is authorized and allowed to comment without pre-moderation?
make a comment with obscene words not be displayed on the site at all?

You can use the "Select an action when uncensored word detected in comment" option. 

image

2) is it possible to initialize the functionality of Comment Censure inside code third-party plugin?

There isn't a definite answer to this question. You should find a file that displays the comments and apply the filter there.  We're really sorry, but we're not familiar with the plugin file system, so we can't help you with this question.


ReplyQuote
Share:
Scroll to top