miniBB ® miniBB®
miniBB Support Forums
 | Forums | Register | Reply | Search | Statistics | Manual |
Custom Tutorials and Modifications miniBB Support Forums / Custom Tutorials and Modifications /   

viewTopicsIfOnlyOneForum=1 + two forums, one hidden. Possible?

Author Ojlert
Registered
#1 | Posted: 5 Dec 2007 07:58 | Edited by: Ojlert 
I have viewTopicsIfOnlyOneForum=1 and would like to keep it that way. However when I added another forum that is supposed to be private for everyone except a select few the other forum isn't displayed.

For ordinary users I want only the topics of the main forum to be show, but for those with access to the private forum both forums should be shown.

Is this a bug or have I forgotten something?

Author Paul
Lead Developer
#2 | Posted: 11 Dec 2007 10:27 
I would suggest that you order your forums that way so the publically shown forum appears first.

Then a little hack would be needed... at the end of your language pack, try to paste this code:

if($user_id>0){
foreach($clForumsUsers as $key=>$val){
if(in_array($user_id, $val)) $viewTopicsIfOnlyOneForum=0;
}
}

it should disable $viewTopicsIfOnlyOneForum if the logged user is listed in some of the $clForumsUsers array elements.

Author Ojlert
Registered
#3 | Posted: 12 Dec 2007 08:07 | Edited by: Ojlert 
Thanks.. But I'll probably remove the viewTopicsIfOnlyOneForum option instead and try to make sure all links point to the main forum. It will be almost the same..

Author Paul
Lead Developer
#4 | Posted: 12 Dec 2007 08:40 
I suppose if you make some of the forum "closed" i.e. using $clForums setting, hidden forums won't be visible until the certain user is logged in. So for "non-allowed" users on the first page you will have just one forum title listed with latest discussions from this forum... if this is suitable for you, then of course it is better to skip all this hassle ;-)

Custom Tutorials and Modifications miniBB Support Forums / Custom Tutorials and Modifications / viewTopicsIfOnlyOneForum=1 + two forums, one hidden. Possible? Top

Your Reply Click this icon to move up to the quoted message

 Short link for this topic:

 ?
Only registered users are allowed to post here. Please, enter your username/password details upon posting a message, or register first.


Before posting, make sure your message is compliant with our forum posting rules. If not, it may be locked or deleted with no explanation.
 
miniBB Support Forums Powered by Forum Software miniBB ® Features  Requirements  Demo  Download  Showcase  Gallery of Arts
Compiler  Premium Extensions  Premium Support  License  Contacts
Proceed with the Captcha add-on: protect your miniBB-forums from the automated spam and flood.
Captcha Addon for miniBB