MyBB Community Forums

Full Version: [PLEASE DELETE]
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Please delete, topic answered!
No need to do all those edits, reverse them and just do this single edit.

Open: showthread.php
Find:
if($forumpermissions['canview'] != 1 || $forumpermissions['canviewthreads'] != 1)
{
	error_no_permission();
}

Replace With:
if($forumpermissions['canview'] != 1 || $forumpermissions['canviewthreads'] != 1 || !$mybb->user['uid'])
{
	error_no_permission();
}

Save & Upload

This will allow guests to see the forums and topic list but when they click on the topic link itself they are prompted with the "no permission error".

The variable $mybb->user['uid'] means "Member's user ID", putting the ! in front of it means "user id has no value".

Hope this helps.
Also, after using the method in in -Calypso-'s post, you need to go to Admin CP > Configuration > Forum Home Posts and "Hide Private Forums?" should be set to No. After that, go ahead and disable "Can view" for guests in the forum permissions.
If you disable "Can View" for guests then they won't be able to see the forum titles or topic titles will they? I may have misunderstood what he was asking for.
They'll get a message to login or register if they try to view a thread.