MyBB Community Forums

Full Version: Remove "Mark this forum read".
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
My forum experience it's only a few days now. Sorry for my very noob questions. Blush

I want to create a forum with very little options because I want the forum to be very user friendly and I want it to look as clean as possible. Cool

I've been able to modify almost everything what I wanted to modify but I got stock here. Dodgy

I want to remove the option "Mark this forum read". Undecided

At least I was able to remove the option "Subscribe to this forum" by removing the following code Big Grin from the FTP file "forumdisplay.php".
// If there are no unread threads in this forum and no unread child forums - mark it as read
require_once MYBB_ROOT."inc/functions_indicators.php";

$unread_threads = fetch_unread_count($fid);
if($unread_threads !== false && $unread_threads == 0 && empty($unread_forums))
{
	mark_forum_read($fid);
}

// Subscription status
$add_remove_subscription = 'add';
$add_remove_subscription_text = $lang->subscribe_forum;

if($mybb->user['uid'])
{
	$query = $db->simple_select("forumsubscriptions", "fid", "fid='".$fid."' AND uid='{$mybb->user['uid']}'", array('limit' => 1));

	if($db->fetch_field($query, 'fid'))
	{
		$add_remove_subscription = 'remove';
		$add_remove_subscription_text = $lang->unsubscribe_forum;
	}
}

Here are the pictures with the option and without.

With the option.
http://i.cubeupload.com/1zYAKH.png

Without the option.
http://i.cubeupload.com/QmXvkY.png

But how can I remove the option "Mark this forum read"? Huh

Thank you very much!! Rolleyes!
You can just take it out of the template - I think that is in the forumdisplay_threadlist template.
(2014-04-21, 11:07 PM)Leefish Wrote: [ -> ]You can just take it out of the template - I think that is in the forumdisplay_threadlist template.
Thanks! I will try that tomorrow! Big Grin

If it's there I think I should be more patient with the tamplates and take a closer look.

It's just hard to figure out which tamplate is the one to modify since there are hundreds of them.

Thanks again! Leefish! Shy
What you can do is if you go to the Home » Board Settings » Server and Optimization Options in Admin panel and set the Output template start/end comments? to YES then when you use the browser tools to inspect your page it will show which template is being used in the HTML. This helps a lot to find which template is which.
(2014-04-22, 06:24 AM)Leefish Wrote: [ -> ]What you can do is if you go to the Home » Board Settings » Server and Optimization Options in Admin panel and set the Output template start/end comments? to YES then when you use the browser tools to inspect your page it will show which template is being used in the HTML. This helps a lot to find which template is which.
OMG! You have made my life million times much easier with this tip.

Million times much easier to modify the forum as I want it thanks to this tip!

Man you rock!

Thanks to this I will be creating my first tutorial too in the next few days! Wink

I'm really extremely amazingly Big Grin happy! Thanks a million!

Do you accept donations? Rolleyes PM me your information if you do. Bitcoins? Litecoins?