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

Hide some users  


sunny
Posts: 57
(@sunny)
Trusted Member
Joined: 3 years ago

Hello, is it possible to hide some users from user list based on usermeta values? For example I would like to hide all users whose usermeta value is user_disabled=1. How can I do that?

4 Replies
Astghik
Posts: 4138
Admin
(@astghik)
Support Team
Joined: 2 years ago

Hi @sunny,

The wpDiscuz User & Comment Mentioning add-on has the following filter you can use for this purpose:

$users = apply_filters('wpdumc_user_search_result', $users, $postID, $ch_user);
Reply
sunny
Posts: 57
(@sunny)
Trusted Member
Joined: 3 years ago

hi @astghik, do you have some documentation or usage example on how it should be used in functions.php?

Reply
1 Reply
Astghik
Admin
(@astghik)
Joined: 2 years ago

Support Team
Posts: 4138

@sunny,

I'm really sorry, but there is no documentation or usage example.

Yes, you should add the custom code in functions.php file. 

Reply
aorchard
Posts: 13
Customer
(@aorchard)
Member
Joined: 2 years ago

I second this question, but would appreciate an actual answer that shows what to do

$users = apply_filters('wpdumc_user_search_result', $users, $postID, $ch_user);

where can we add in the usernames we want to exclude in this code?

Reply
Share: