2011-06-15, 03:53 PM
2011-06-15, 04:41 PM
http://mods.mybb.com/view/hide-links-to-guests-for-14
For hiding to members with less than 5 posts, you'll need to set up group promotion. And modify the plugin file a bit.
First of all change the compatibility, change:
And then to add extra groups, search:
For hiding to members with less than 5 posts, you'll need to set up group promotion. And modify the plugin file a bit.
First of all change the compatibility, change:
"compatibility" => "14*"
to "compatibility" => "16*"
And then to add extra groups, search:
if($mybb->user['usergroup'] == "1")
toif(in_array($mybb->user['usergroup'],array(1,5,7,X)))
This also includes: Awaiting activation and the Banned usergroup. You'll need to replace the X with the ID of the usergroup with -5 posts.2011-06-15, 06:04 PM
I didn't understand the part where I'm supposed to add: if(in_array($mybb->user['usergroup'],array(1,5,7,X)))
2011-06-15, 07:10 PM
You need to search for this line:
if($mybb->user['usergroup'] == "1")
and replace it with (if you also want to include registered users)if(in_array($mybb->user['usergroup'],array(1,2,5,7)))
2011-06-15, 08:34 PM
(2011-06-15, 07:10 PM)Aries-Belgium Wrote: [ -> ]You need to search for this line:
and replace it with (if you also want to include registered users)if($mybb->user['usergroup'] == "1")
if(in_array($mybb->user['usergroup'],array(1,2,5,7)))
Where do I search for that?
2011-06-15, 08:40 PM
^ in the plugin's php file which you copy to your plugin's directory on the server
2011-06-15, 08:43 PM
(2011-06-15, 08:34 PM)mukilol Wrote: [ -> ](2011-06-15, 07:10 PM)Aries-Belgium Wrote: [ -> ]You need to search for this line:
and replace it with (if you also want to include registered users)if($mybb->user['usergroup'] == "1")
if(in_array($mybb->user['usergroup'],array(1,2,5,7)))
Where do I search for that?
In the same file you made the compatibility changes.
2011-06-15, 09:19 PM
Small problem...
I replaced the code and the usergroups are getting the message but how do I place the 5 post requirement? The current usergroups can't see the link even if they have and don't have more thank 5 posts.
How do I place the requirement?
Found a plugin, everything is ok now.
I replaced the code and the usergroups are getting the message but how do I place the 5 post requirement? The current usergroups can't see the link even if they have and don't have more thank 5 posts.
How do I place the requirement?
Found a plugin, everything is ok now.
2011-06-15, 10:21 PM
You don't need a plugin for that. Just use Group Promotion. Look at the link I posted above.