Zainstalowałem mod: Last Topic Title i mam pewien problem, otóż:
klikając w nazwe tematu np. Regulamin (jak na zdjeciu) chciałbym aby hiperłącze było skierowane
do tematu, a nie do ostatniego postu..
Ktoś wie jak to zrobić?
Z góry dziekuje za pomoc.
kawałek kodu moda:
Kod: Zaznacz cały
//-- MOD BEGIN: Last Topic Title on Index -------------------
$ltid = $forum_data[$j]['topic_id'];
$lttitle = $forum_data[$j]['topic_title'];
//
// Censor topic title
//
if ( count($orig_word) )
{
$lttitle = preg_replace($orig_word, $replacement_word, $lttitle);
}
$altlttitle = $lttitle;
$lang_in = $lang['in'];
//
// Filter topic_title if not allowed to read
//
if (!$auth_read_ary[$forum_data[$j]['forum_id']]['auth_read'])
{
$lttitle = '';
$lang_in = '';
}
// undo_htmlspecialchars();
$lttitle = preg_replace($unhtml_specialchars_match, $unhtml_specialchars_replace, $lttitle);
// do_htmlspecialchars();
// set length of topic title to 25 characters
$lttitle = preg_replace($html_entities_match, $html_entities_replace, (strlen($lttitle) > 25) ? substr($lttitle,0,25) . '...' : $lttitle);
$last_post .= $lang_in . ' ' . '<a title="' . $altlttitle . '" alt="' . $altlttitle . '" href="' . append_sid("viewtopic.$phpEx?" . POST_TOPIC_URL . "=$ltid") . '">' . $lttitle . '</a><br />';
$last_post .= ( $forum_data[$j]['user_id'] == ANONYMOUS ) ? $lang['by'] . ' ' . ( ($forum_data[$j]['post_username'] != '' ) ? $forum_data[$j]['post_username'] . ' ' : $lang['Guest'] . ' ' ) : $lang['by'] . ' ' . '<a href="' . append_sid("profile.$phpEx?mode=viewprofile&" . POST_USERS_URL . '=' . $forum_data[$j]['user_id']) . '">' . $forum_data[$j]['username'] . '</a> ';
//-- MOD END: Last Topic Title on Index -------------------