MyBB Community Forums

Full Version: Help Needed - Why do permissions not work in Multiforums? Any ideas?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello All,

I've been having a weird problem with MyBB having been modified for Multiforums / Forum Hosting. The weird thing is that forum permissions are either ignored or don't work. For instance, I can set a forum to be invisible to guests via the MyBB Admin CP / Permissions and yet it appears on the index for guests.

The weird thing is that this only happens in conjunction with my MyBB Multiforums Mod, so MyBB isn't liking something about the multiforums mod as I don't have this problem with standalone / normal MyBB forums.

You can see what I mean by making a forum here. Try making a forum and then try setting a forum or category to be invisible to guests, then log out. You'll probably be able to see the "hidden" category still.

So, I'm wondering, does anyone have any ideas as to why this may happen? As far as I know I did not modify anything related to the MyBB permissions system in making my mod, but something may be off. I'm running on the link above MyBB 1.4.2 patched to MyBB 1.4.3 manually via the changed files package. I also had this issue with MyBB 1.4.0 and every 1.4 version since. Also, CreateMyBB has also had similar issues with MyBB 1.2 as there are complaints of this on their support forums as well.

The only thing I can think is that if the permissions system uses the MyBB get_current_location function in some way as sometimes with my mod I know that the php_self function in that function does not work correctly due to the virtual forums / directories. I don't think though that this would affect the permissions.

If anyone has any insight into why I am having this problem I would be very grateful. Is there some code I need to look at / modify to fix this or any likely suspects?

Thanks,
Brandon
Are the forums and forumspermissions caches correctly updated?
(2008-10-30, 06:26 PM)DennisTT Wrote: [ -> ]Are the forums and forumspermissions caches correctly updated?

Actually, no they are not. It seems too that I am getting duplicate caches that all contain the same, yet incorrect data. Rebuilding them does nothing other than spawn another cache in the list with the same data. (See screenshot attached below.)

Other than the permissions error though this has not caused any problems with the forums other than large caches.

Thanks,
Brandon
The datacache class uses a "REPLACE INTO" query, and the title field in the datacache table should be a primary key so duplicate titles should not be allowed.
Ok, thanks. Yeah, it may be my automated installer then causing this issue as I don't think the way it's currently written that it honors the primary key setting. I'll try altering it and hopefully this will solve both issues.

I'll let you know how it goes.

Thanks for the help. Yeah, this is probably the issue then.

Thanks,
BMR777