Changes the color of the links if there are new posts
Screenshot index:
Screenshot viewforum:
Topic @ phpBB.nl: http://www.phpbb.nl/viewtopic.php?t=14451
Code: Select all
##############################################################
## MOD Title: Colored link if new post
## MOD Author: DaMnNaTiOn < fy [at] frankyang [dot] net > (Frank Yang) http://www.frankyang.net
## MOD Description: Changes the color of the links if there are new posts
## MOD Version: 0.2.0
##
## Installation Level: Easy
## Installation Time: 5 Minutes
## Files To Edit: index.php
## viewforum.php
## templates/subSilver/index_body.tpl
## templates/subSilver/viewforum_body.tpl
## Included Files: n/a
## License: http://opensource.org/licenses/gpl-license.php GNU General Public License v2
##############################################################
## For security purposes, please check: http://www.phpbb.com/mods/
## for the latest version of this MOD. Although MODs are checked
## before being allowed in the MODs Database there is no guarantee
## that there are no security problems within the MOD. No support
## will be given for MODs not found within the MODs Database which
## can be found at http://www.phpbb.com/mods/
##############################################################
## Author Notes: Nothing :)
##############################################################
## MOD History:
##
## 2005-11-20 - Version 0.2.0
## - Added the link highlighting in viewforum.php
##
## 2005-11-19 - Version 0.1.1
## - Simplified the install, the color is now hardcoded in the php file instead of the css file
##
## 2004-11-26 - Version 0.1.0
## - Initial Release
##
##############################################################
## Before Adding This MOD To Your Forum, You Should Back Up All Files Related To This MOD
##############################################################
#
#-----[ OPEN ]------------------------------------------
#
index.php
#
#-----[ FIND ]------------------------------------------
#
$folder_alt = ( $unread_topics ) ? $lang['New_posts'] : $lang['No_new_posts'];
#
#-----[ AFTER, ADD ]------------------------------------------
#
# Change #d82929 to any color you like
$new_posts_link = ( $unread_topics ) ? ' style="color: #d82929;"' : '';
#
#-----[ FIND ]------------------------------------------
#
'ROW_CLASS' => $row_class,
#
#-----[ AFTER, ADD ]------------------------------------------
#
'NEW_POSTS_LINK' => $new_posts_link,
#
#-----[ OPEN ]------------------------------------------
#
viewforum.php
#
#-----[ FIND ]------------------------------------------
#
$folder_image = $folder_new;
#
#-----[ AFTER, ADD ]------------------------------------------
#
# Change #d82929 to any color you like
$new_posts_link = ' style="color: #d82929;"';
#
#-----[ FIND ]------------------------------------------
#
$folder_image = $folder_new;
#
#-----[ AFTER, ADD ]------------------------------------------
#
$new_posts_link = ' style="color: #d82929;"';
#
#-----[ FIND ]------------------------------------------
#
'ROW_CLASS' => $row_class,
#
#-----[ AFTER, ADD ]------------------------------------------
#
'NEW_POSTS_LINK' => $new_posts_link,
#
#-----[ OPEN ]------------------------------------------
#
templates/subSilver/index_body.tpl
#
#-----[ FIND ]------------------------------------------
#
<td class="row1" width="100%" height="50">
#
#-----[ IN-LINE FIND ]------------------------------------------
#
<span class="forumlink"> <a href="{catrow.forumrow.U_VIEWFORUM}" class="forumlink">{catrow.forumrow.FORUM_NAME}</a>
#
#-----[ IN-LINE REPLACE WITH ]------------------------------------------
#
<span{catrow.forumrow.NEW_POSTS_LINK} class="forumlink"> <a href="{catrow.forumrow.U_VIEWFORUM}">{catrow.forumrow.FORUM_NAME}</a>
#
#-----[ OPEN ]------------------------------------------
#
templates/subSilver/viewforum_body.tpl
#
#-----[ FIND ]------------------------------------------
#
<span class="topictitle">{topicrow.NEWEST_POST_IMG}{topicrow.TOPIC_TYPE}<a href="
#
#-----[ IN-LINE FIND ]------------------------------------------
#
{topicrow.U_VIEW_TOPIC}"
#
#-----[ IN-LINE AFTER, ADD ]------------------------------------------
#
{topicrow.NEW_POSTS_LINK}
#
#-----[ SAVE/CLOSE ALL FILES ]------------------------------------------
#
# EoM