Seite 1 von 2
Easy Sub-Forums v1.0.8 - > Problem in index.php
Verfasst: 29.02.2008 19:44
von ARaeppel
Hallo,
ich hab das MOD eingebaut und bekomme nun eine Fehlermeldung:
Parse error: parse error, unexpected T_VARIABLE in /home/www/htdocs/xxx.de/forum/index.php on line 539
Hier ab Zeile 538
// Added by Easy Sub-Forums MOD
$attached_forum_count = count($attached_forums);
if($attached_forum_count)
{
$template->assign_block_vars('catrow.forumrow.switch_attached_forums', array(
'L_ATTACHED_FORUMS' => ($attached_forum_count ==1)? $lang['Attached_forum']: $lang['Attached_forums']
));
if (count($forum_moderators[$forum_id]) > 0 )
{
$template->assign_block_vars('catrow.forumrow.switch_attached_forums.br', array());
}
for($k = 0; $k < $attached_forum_count; $k++)
{
$template->assign_block_vars('catrow.forumrow.switch_attached_forums.attached_forums', array(
'FORUM_IMAGE' => $attached_forums[$k]['sub_img'],
'FORUM_NAME' => $attached_forums[$k]['sub_name'],
'L_FORUM_IMAGE' => $attached_forums[$k]['sub_alt'],
'U_VIEWFORUM' => $attached_forums[$k]['sub_url']
));
}
}
// END added by Easy Sub-Forums MOD
André
Verfasst: 29.02.2008 20:01
von Balint
Hallo!
Könntest du bitte die komplette index.php
zum Download bereitstellen? So ist es wenig aufschlußreich...
Viele Grüße,
Bálint
Datei
Verfasst: 29.02.2008 20:15
von ARaeppel
Hallo,
hab nochmal die Originaldatei ohne MOD neu bearbeitet. Jetzt ist die Zeile anders:
Parse error: parse error, unexpected T_ELSE in /home/www/htdocs/xxx.de/forum/index.php on line 451
//Edit: Link gelöscht weil Datei nicht mehr vorhanden
André
MOD
Verfasst: 29.02.2008 20:18
von ARaeppel
hier die Stelle im MOD:
#
#-----[ FIND ]------------------------------------------------
#
$last_post_time = create_date($board_config['default_dateformat'], $forum_data[$j]['post_time'], $board_config['board_timezone']);
$last_post = $last_post_time . '<br />';
$last_post .= ( $forum_data[$j]['user_id'] == ANONYMOUS ) ? ( ($forum_data[$j]['post_username'] != '' ) ? $forum_data[$j]['post_username'] . ' ' : $lang['Guest'] . ' ' ) : '<a href="' . append_sid("profile.$phpEx?mode=viewprofile&" . POST_USERS_URL . '=' . $forum_data[$j]['user_id']) . '">' . $forum_data[$j]['username'] . '</a> ';
$last_post .= '<a href="' . append_sid("viewtopic.$phpEx?" . POST_POST_URL . '=' . $forum_data[$j]['forum_last_post_id']) . '#' . $forum_data[$j]['forum_last_post_id'] . '"><img src="' . $images['icon_latest_reply'] . '" border="0" alt="' . $lang['View_latest_post'] . '" title="' . $lang['View_latest_post'] . '" /></a>';
#
#-----[ REPLACE WITH ]----------------------------------------
#
// Modified by Easy Sub-Forums MOD
if (strlen($forum_data[$j]['topic_title'])>=25)
{
$forum_data[$j]['topic_title']=substr($forum_data[$j]['topic_title'],0,25). "...";
}
$last_post_time = create_date($board_config['default_dateformat'], $forum_data[$j]['post_time'], $board_config['board_timezone']);
$last_post = '' . $last_post_time . '' . '<br />';
$last_post .= ( $forum_data[$j]['user_id'] == ANONYMOUS ) ? ( ($forum_data[$j]['post_username'] != '' ) ? $forum_data[$j]['post_username'] . ' ' : $lang['Guest'] . ' ' ) : '<a href="' . append_sid("profile.$phpEx?mode=viewprofile&" . POST_USERS_URL . '=' . $forum_data[$j]['user_id']) . '">' . $forum_data[$j]['username'] . '</a> <a href="' . append_sid("viewtopic.$phpEx?" . POST_POST_URL . '=' . $forum_data[$j]['forum_last_post_id']) . '#' . $forum_data[$j]['forum_last_post_id'] . '"><img src="' . $images['icon_latest_reply'] . '" border="0" alt="' . $lang['View_latest_post'] . '" title="' . $lang['View_latest_post'] . '" /></a>';
// END Modified by Easy Sub-Forums MOD
Verfasst: 29.02.2008 20:20
von Balint
Hallo!
Bitte immer darauf achten, das vor und nach den Einfügungen eine Zeile leer bleibt bzw. in eine neue Zeile kopiert wird!
Finde:
ersetze mit
Viele Grüße,
Bálint
noch da
Verfasst: 29.02.2008 20:28
von ARaeppel
Hallo,
das war nur ein Schusselfehler beim 2. Versuch. Jetzt wandert der Fehler in Zeile 493. index.txt ist aktualisiert
Verfasst: 29.02.2008 20:41
von Balint
Hallo!
Zeile 515:
muß in eine NEUE Zeile vor Zeile 492 (// Added by Easy Sub-Forums MOD)
Viele Grüße,
Bálint
Fehler
Verfasst: 29.02.2008 20:46
von ARaeppel
ja hallo, schönen Dank für die schnelle Hilfe. Jetzt meckert er Zeile 526
André
Verfasst: 29.02.2008 20:51
von Balint
Hallo!
Lösche die erste schließende geschweifte Klammer nach der Zeile
"// END added by Easy Sub-Forums MOD" (also die Klammer in der Zeile 517) .
Viele Grüße,
Bálint
Verfasst: 29.02.2008 20:58
von ARaeppel
dann kommt aber Zeile 561 Irgendwie fehlt ihm da ne Klammer