1 頁 (共 1 頁)

[討論]主題類型MOD(Ver. 4)和Split topic type衝突

發表於 : 2007-01-13 03:51
ghostx2
參考連結:主題類型MOD(Ver. 4)
     Split topic type 1.0.5(公告置頂分區)


主題類型MOD(Ver. 4)安裝時
在templates/subSilver/viewforum_body.tpl
--------------------------------------------------------------------------------------#
#-----[ FIND ]-----------------------------
#
<td class="row1" width="100%"><span class="topictitle">{topicrow.NEWEST_POST_IMG}{topicrow.TOPIC_TYPE}<a href="{topicrow.U_VIEW_TOPIC}" class="topictitle">{topicrow.TOPIC_TITLE}</a></span><span class="gensmall"><br />

#
#-----[ IN-LINE FIND ]---------------------
#
{topicrow.TOPIC_TYPE}

#
#-----[ IN-LINE AFTER, ADD ]---------------
#
{topicrow.TYPES_NAME}

--------------------------------------------------------------------------------------

這一段在Split topic type有衝突到

--------------------------------------------------------------------------------------
#
#-----[ FIND ]------------------------------------------------
#
<td class="row1" align="center" valign="middle" width="20"><img src="{topicrow.TOPIC_FOLDER_IMG}" width="19" height="18" alt="{topicrow.L_TOPIC_FOLDER_ALT}" title="{topicrow.L_TOPIC_FOLDER_ALT}" /></td>
<td class="row1" width="100%"><span class="topictitle">{topicrow.NEWEST_POST_IMG}{topicrow.TOPIC_TYPE}<a href="{topicrow.U_VIEW_TOPIC}" class="topictitle">{topicrow.TOPIC_TITLE}</a></span><span class="gensmall"><br />
{topicrow.GOTO_PAGE}</span></td>
<td class="row2" align="center" valign="middle"><span class="postdetails">{topicrow.REPLIES}</span></td>
<td class="row3" align="center" valign="middle"><span class="name">{topicrow.TOPIC_AUTHOR}</span></td>
<td class="row2" align="center" valign="middle"><span class="postdetails">{topicrow.VIEWS}</span></td>
<td class="row3Right" align="center" valign="middle" nowrap="nowrap"><span class="postdetails">{topicrow.LAST_POST_TIME}<br />{topicrow.LAST_POST_AUTHOR} {topicrow.LAST_POST_IMG}</span></td>
#
#-----[ REPLACE WITH ]----------------------------------------
# add row. in front of each field, also set title width to 100%
<td class="row1" align="center" valign="middle" width="20"><img src="{row.topicrow.TOPIC_FOLDER_IMG}" width="19" height="18" alt="{row.topicrow.L_TOPIC_FOLDER_ALT}" title="{row.topicrow.L_TOPIC_FOLDER_ALT}" /></td>
<td class="row1" width="100%"><span class="topictitle">{row.topicrow.NEWEST_POST_IMG}{row.topicrow.TOPIC_TYPE}<a href="{row.topicrow.U_VIEW_TOPIC}" class="topictitle">{row.topicrow.TOPIC_TITLE}</a></span><span class="gensmall"><br />
{row.topicrow.GOTO_PAGE}</span></td>
<td class="row2" align="center" valign="middle"><span class="postdetails">{row.topicrow.REPLIES}</span></td>
<td class="row3" align="center" valign="middle"><span class="name">{row.topicrow.TOPIC_AUTHOR}</span></td>
<td class="row2" align="center" valign="middle"><span class="postdetails">{row.topicrow.VIEWS}</span></td>
<td class="row3Right" align="center" valign="middle" nowrap="nowrap"><span class="postdetails">{row.topicrow.LAST_POST_TIME}<br />{row.topicrow.LAST_POST_AUTHOR} {row.topicrow.LAST_POST_IMG}</span></td>

--------------------------------------------------------------------------------------

因為找不到{topicrow.TOPIC_TYPE}
假使{topicrow.TYPES_NAME}直接加在{row.topicrow.TOPIC_TYPE}後面
會造成標題前面沒有顯示出主題類型
故將{topicrow.TYPES_NAME}改成{row.topicrow.TYPES_NAME}
再加在{row.topicrow.TOPIC_TYPE}後面
標題前面就能正常顯示出主題類型