phpBB3: Last Post Subject on Board Index

This is a modification you can find easily in the Knowledge Base section on the phpBB website. However, I have made some slight alterations to the template edit, as well as increased the number of characters allowed for the subject to be displayed. Keep in mind that I only use proSilver-based styles, and so the smaller 10-character limit is more suitable for subSilber-based styles. On top of that, the difference in template changes are specifically for proSilver-based styles as well, and would not work for subSilver.

A sample of how the subject will look on the board index.phpBB3: Last Post Subject on Board Index

The link to the original mod article is here.

#
#—-[ OPEN ]———————————————————–
#

includes/functions_display.php

#
#—-[ FIND ]———————————————————–
#

			'LAST_POST_SUBJECT'		=> censor_text($last_post_subject),

#
#—-[ REPLACE WITH ]—————————————————
#

			'LAST_POST_SUBJECT'		=> (utf8_strlen(censor_text($last_post_subject)) > 30) ? utf8_substr(censor_text($last_post_subject), 0, 30) . '...' : censor_text($last_post_subject),

#
#—-[ OPEN ]———————————————————–
#

styles/prosilver/template/forumlist_body.html

#
#—-[ FIND ]———————————————————–
#

						<!-- IF forumrow.U_UNAPPROVED_TOPICS --><a href="{forumrow.U_UNAPPROVED_TOPICS}">{UNAPPROVED_IMG}</a><!-- ENDIF -->
						<!-- IF forumrow.LAST_POST_TIME --><dfn>{L_LAST_POST}</dfn> {L_POST_BY_AUTHOR} {forumrow.LAST_POSTER_FULL}
						<!-- IF not S_IS_BOT --><a href="{forumrow.U_LAST_POST}">{LAST_POST_IMG}</a> <!-- ENDIF --><br />{forumrow.LAST_POST_TIME}<!-- ELSE -->{L_NO_POSTS}<br />&nbsp;<!-- ENDIF --></span>

#
#—-[ REPLACE WITH ]—————————————————
#

						<!-- IF forumrow.U_UNAPPROVED_TOPICS --><a href="{forumrow.U_UNAPPROVED_TOPICS}">{UNAPPROVED_IMG}</a><!-- ENDIF -->
						<!-- IF forumrow.LAST_POST_TIME --><a href="{forumrow.U_LAST_POST}">{forumrow.LAST_POST_SUBJECT}</a><dfn>{L_LAST_POST}</dfn>
						<br />{forumrow.LAST_POST_TIME} {L_POST_BY_AUTHOR} {forumrow.LAST_POSTER_FULL}
						<!-- ELSE -->{L_NO_POSTS}<br />&nbsp;<!-- ENDIF --></span>