==README for Unread messages indicator add-on for miniBB==
Release date: February 12, 2009.
Most recent update: February 4, 2026.
miniBB version: 3.0+
Author: Paul Puzyrev (minibb.com)

This add-on gives an opportunity to follow messages posted since the last checking point, indicating a special icon straight on forums pages, under "Recent Topics" section, optionally Forums section and internal topics listings. Works only for registered and logged members. Read topics info could be stored in a cookie or mySQL table.

This add-on is being developed completely on the sponsorship base, it is initially sponsored by www.tdt3d.com, extensions by 7-dna.com.
If you would like to extend this add-on even more, use the contact form on miniBB.com to make your offer to developers, suggesting your budget and requirements.


==SETUP==


Modify bb_plugins.code.txt and optionally change some options explained. In most cases default options suit almost everything, so you need to decide what kind of module will you use, cookies (stored on the client's side with no affection to the performance of database, but limited only by one computer) or database (could be used on different computers, but will obviously affect the performance of database, specially on large forums). After your decision, set up $unreadMsgMode properly. 

If mySQL will be used, specify different table names for additional two tables installed, complying with your current miniBB table names. Then install mySQL tables, executing unread.sql.

Under $resetReadLink, specify HTML code for the link which could be pasted anywhere in templates. This link is necessary to proceed the final step, when a member has read all messages. Paste {$resetReadLink} in 'templates/main_footer.html' as for example after `{$l_adminpanel_link}`. Then this link would appear at the bottom of all pages.


==INSTALLATION==


* Copy /img/unread.gif to your forums /img/ folder. This is an icon which will be placed near topic titles. You are allowed to modify it to meet your own taste.

* In bb_plugins.php, paste the code provided in bb_plugins.code.txt. 

* In bb_plugins.php, locate the function parseTopic() - it may be used by other add-ons already. If it's not here, just paste the full code from bb_plugins_parseTopic.code.txt, else just take the proper block which should be inserted before the 'return' statement of that function.

* Modify /templates/main_last_discuss_cell.html OR /templates/main_modern_lcell.html (depends on what kind of default layout schema you are using for miniBB) and /templates/main_topics_cell.html, pasting {$unreadicon} preferrably BEFORE <a href...> tag indicating topic's title. The icon will indicate new messages posted since the last checking point.

* If you want the "Unread" icon appearing also in the forums list on the first page (near each forum's title), in bb_plugins.php set `$showIconInForums=TRUE;`. Currently, this is only supported if `$unreadMsgMode=0;` is set. Then modify 'templates/main_forums_cell.html' (if you have `$startPageModern=FALSE;`) or 'templates/main_modern_fcell.html' (if you have `$startPageModern=TRUE;`) and paste the following var indicating the 'Unread' icon: {$forumPosts[$forum]}. For example, it could look that way in 'templates/main_modern_fcell.html':

<td class="tbTransparent txtL vmiddle" style="width:80%"><strong><a href="{$linkToForums}" title="{$forum_title}">{$forum_title}</a></strong>{$forumPosts[$forum]}</td>

<td class="forumTitle" style="width:95%">
<a href="{$linkToForums}" title="{$forum_title}" class="mnblnk">{$forum_title}</a>{$forumPosts[$forum]}
</td>

==USAGE==


When you log-in for the first time, all topics will be marked "unchecked" by default. If you read some topic, the "unchecked" indicator should disappear as the topic is entered into the "checked list"; however if somebody posts a new message while you are reading other topics, indicator should re-appear again. Since the holder keeps only limited amount of topics (100 by default), the earlier topic you have read may be replaced by a newer topic. To handle this process more properly, after each reading when you think you are done, you need to click the "Mark all messages read" link to restore the checking point, so next time only messages posted later than this point, will be marked as "unchecked".

Such algorithm doesn't comply with the rule of actually "unread" messages. It only indicates new messages posted since some checking point. The only forums tool to use for a very precise and comfortable new messages checking/reading at once, is our branding "Forums Checker" program. https://www.minibb.com/checker.html


==FINALLY==
Questions? Suggestions? Improvements? Post them quickly on our support forums:
https://www.minibb.com/forums/
