2017-11-04, 10:44 PM
Hello,
I'm trying to hide a specific forum to a user. I know I can do that from the forum settings but I can't use this features because many users from the same group can have different access level (based on my plugin).
Explain the structure is how my plugin works will be long and worthless so instead I'll just explain what behavior I need.
If I edit the function build_forumbits and add this code
Just before the run_hook method :
The forum with id 9 didn't display on the page.
And this is exactly what i'm trying to do but from my plugin file (using the hook system).
PS. In really it's more complex but explain why I don't create different group etc will be long so if I can hide the forum with id 9 from inside my plugin hook it will resolve my problem )
Thanks
I'm trying to hide a specific forum to a user. I know I can do that from the forum settings but I can't use this features because many users from the same group can have different access level (based on my plugin).
Explain the structure is how my plugin works will be long and worthless so instead I'll just explain what behavior I need.
If I edit the function build_forumbits and add this code
if($forum['fid'] == 9)
{
continue;
}
Just before the run_hook method :
$forum = $plugins->run_hooks("build_forumbits_forum", $forum);
The forum with id 9 didn't display on the page.
And this is exactly what i'm trying to do but from my plugin file (using the hook system).
PS. In really it's more complex but explain why I don't create different group etc will be long so if I can hide the forum with id 9 from inside my plugin hook it will resolve my problem )
Thanks