miniBB ® 


Support Forums
 | Start | Register | Search | Statistics | File Bank | Manual |
How To miniBB Support Forums / How To /  

defining Private forums

Page  Page 1 of 2:  1  2  Next »

Author fruitfly
#1 | Posted: 4 Jan 2004 01:58 
Ok, I have a little problem that I can't figure out. On my site, I have 2 forums that I want to remain private. Ok, forums 7 and 8 are meant to be private, and they were working fine before. Then, I noticed one was no longer private. I did a bit of looking and which ever one is first in the list, is public and the second is's my bb_specials to better explain..


Which ever one is done first, doesn't go private, it stays open to the public. This is how I have it now, and 8 is open to the public and 7 is private...if 7 is first then it is public. I am sure I'm missing something simple, but I can't see what it is.

It was working fine before, the only thing I've done is install the email plugin, and I don't see how one would effect the other.

Any help is appreciated.

Author 4days
#2 | Posted: 5 Jan 2004 02:59 
you're redefining the array by listing it again (so the second definition overwrites the first).

write it as:


Author fruitfly
#3 | Posted: 5 Jan 2004 06:40 
oooooh, I knew it had to be something simple. Thank you very much.

Author gruffnuts
#4 | Posted: 22 Jul 2005 15:33 
I am wondering how to make forums really private. If I use this $clForums=array(1,2,3); in bb_specials.php I thought that would make the first three added forums private: ie. invisible and unpostable by users until allowed in the $clForumsUsers[]=array(); line.

Instead, any visitor to the page or new user seems to be able to see and use the forums. Is this right or am I doing something wrong?


Author Team
#5 | Posted: 22 Jul 2005 15:56 
Yes, this is right until you specify the $clForumsUsers arrays. Example (this must be specified):


where 4,10,90,11,12,13 are allowed user IDs. Array also could be empty - in this case, only admin (and optionally moderator) has access to that forum.

Author gruffnuts
#6 | Posted: 22 Jul 2005 16:06 
Thanks for your reply. Maybe I am misunderstanding something. Currently, I have one forum, no users, and have the lines:


Then by your explanation, the forum ID1 should be hidden.

But...I don't have any users yet, so I can't specify any for the second line. However, in the meantime, if I simply go to the site as a visitor, I can see and read forum ID1, sign in and post to it, despite it being specified as closed. Should I start over??

Author Team
#7 | Posted: 22 Jul 2005 16:18 
If you are logged as admin, this forum will be visible, of course. But if you logged out and are Anonymous, it shouldn't be visible. And be sure that forum's ID is really 1.

Author gruffnuts
#8 | Posted: 22 Jul 2005 16:28 
Thanks Team.

Yes, I understand I will see all forums when logged in as admin. But when I log out, or log in as a new user, or an added user not specified in the arrays, I can see all the forums and post to them. I have even tried visiting the forum from a different PC on a different network! So it's got me beat.

How do I know if the forum's ID is 1? I presumed if I only have one forum it's ID must be one. If I have two, the first and second would be ID 1 and 2 respectively. Is this right, or have I got to assign an ID somewhere?


Author gruffnuts
#9 | Posted: 22 Jul 2005 16:45 
Eureka! I notice that after adding and deleting users, the second user was ID5! Having added and deleted some forums, I didn't realise that the count hadn't zeroed. I had to check my mySQL db to see that what I thought were forums one and two were actually 4 and 5.

Now, is there any way of working out the IDs of the forums, if, like me, you have done a lot of troubleshooting, adding and deleting without going to your webspaces' mysql cpanel?

Anyway, thanks for your help.

PS: It is syntax requirement that each private forum is put on a separate line $clForumsUsers[1]=array(); is that correct?

Author Team
#10 | Posted: 22 Jul 2005 17:09 

Author coco
#11 | Posted: 30 Nov 2006 07:01 
I have one private forum and everything works fine.
On the index page users can see that private forum only when they logged in.

How to make that private forum visible for not registered users (logged out users) on the index page, but they can't get in as an anonimus (acess denied), and they can't see latest discussions made in that forum.

I hope that you uderstand what i'm tryig to say.


Author Paul
Lead Developer 
#12 | Posted: 30 Nov 2006 07:37 
How to make that private forum visible for not registered users (logged out users) on the index page... -

if you are talking only about 1st page, then the only way to achieve that, is to make a core destructive change in the file bb_func_vforum.php. Before the condition if($show){ you need to paste:


Author coco
#13 | Posted: 17 Aug 2007 12:04 
core destructive change in the file bb_func_vforum.php
that's not recommended or?

Author tom322
Active Member
#14 | Posted: 17 Aug 2007 12:13 
that's not recommended or?
I think only because you must keep track of the custom changes when you want to upgrade the script. So it takes more time and patience if you make a core-destructive change. Other than that, the solution will work perfectly.

Author coco
#15 | Posted: 17 Aug 2007 12:18 
o.k. thanks!

Page  Page 1 of 2:  1  2  Next » 
How To miniBB Support Forums / How To /
 defining Private forums
 Share Topic's Link

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

Post as a Guest, leaving the Password field blank. You could also enter a Guest name, if it's not taken by a member yet. Sign-in and post at once, or just sign-in, bypassing the message's text.

Before posting, make sure your message is compliant with forum rules; otherwise it could be locked or removed with no explanation.


miniBB Support Forums Powered by Forum Software miniBB ® Home  Features  Requirements  Demo  Download  Showcase  Gallery of Arts
Compiler  Premium Extensions  Premium Support  License  Contact Us
Check out the Captcha add-on: protect your miniBB-forums from the automated spam and flood.