The effects of alcohol on sustanon 250 leucine for – real weight loss & bodybuilding benefits?
Suspending voting o...
 
Share:
Notifications
Clear all

Suspending voting on certain comments or individual posts?

4 Posts
2 Users
0 Reactions
900 Views
Sophie
Posts: 26
Topic starter
(@sophie)
Eminent Member
Joined: 4 years ago

This isn't really an issue, more of a plea.

Can you please find a way to enable voting to be suspended on certain comments or on certain articles?

You guys have been awesome in providing extra functionality on demand  in the past, so I'm hoping you can also pull this off!

it would make a huge improvement to this admin's working life! 

 

 

 

Topic Tags
3 Replies
Asti
Posts: 7617
 Asti
Support
(@asti)
Illustrious Member
Joined: 7 years ago

 Hi Sophie,

You can use the following hook-code:

add_filter("wpdiscuz_comment_list_args", function ($args) {
    if (in_array($args["post_id"], [X,])) {
        $args["components"]["vote.html"] = "";
    }
    return $args;
});

Just replace the red marked value with the comma-separated post IDs where you want to hide voting buttons. 

The code should be put in the active theme functions.php file. 

 

Reply
2 Replies
Sophie
(@sophie)
Joined: 4 years ago

Eminent Member
Posts: 26

@asti thanks that's a great help!

This will disable votes of comments in specified posts, right? is there a way to do it for specific posters - eg to disallow votes on admin comments? 

Reply
Asti
 Asti
Support
(@asti)
Joined: 7 years ago

Illustrious Member
Posts: 7617

@sophie,

I'm really sorry, but there isn't an easy solution we can post here. 

Currently, we have plugin customization and custom addon development services at the gVectors Team. They can assess the work and create it for you. Just contact us via sales[at]gvectors.com email address and send a list of requirements you'd like to have.

Reply
Share: