Seite 1 von 1

phpBBChatSpot v1.0.0: Fehlermeldung im Forum

Verfasst: 03.10.2004 13:48
von Piet
Hallo Leute,

ich teste den phpBBChatSpot v1.0.0 aus (lokal auf dem PC mit XAMPP).
Der Grund, warum ich den nehme: ich will im Forum-Index sehen, wer im Chat ist.
Alles soweit gemacht, und bei dem Forum-Index bekomme ich folgende Fehlermeldung:

Code: Alles auswählen

Parse error: syntax error, unexpected ';', expecting ')' in C:\xampp\htdocs\phpBB2\index.php on line 270
In der Zeile 270 steht folgender Code:
require_once( $phpbb_root_path . 'chatspot_front.' . $phpEx );
Im root gibt es die Datei 'chatspot_front.'

Kann mir da jemand helfen?

Verfasst: 03.10.2004 14:03
von raphael
Nenn mal einen größeren Code-Abschnitt.
Die Fehlermeldung besagt, dass eine Klammer erwartet wird. Vielleicht fehlt diese ja einfach. Also gib mal einen größeren Abschnitt aus der index.php, damit der Zusammenhang deutlich wird.

Verfasst: 03.10.2004 14:15
von Piet
OK. Danke schon mal für die Antwort.
Ich hatte nur diese eine Zeile gepostet, weil das die einzigste war, die in diesem Abschnitt eingefügt wurde.

Hier mehr:

Code: Alles auswählen

	// Find which forums are visible for this user
	//
	$is_auth_ary = array();
	$is_auth_ary = auth(AUTH_VIEW, AUTH_LIST_ALL, $userdata, $forum_data);

	//
	// Start output of page
	//
	define('SHOW_ONLINE', true);
	$page_title = $lang['Index'];
	include($phpbb_root_path . 'includes/page_header.'.$phpEx);

	$template->set_filenames(array(
		'body' => 'index_body.tpl')
	);

	$template->assign_vars(array(
// ******************** BEGIN phpBBChatSpot MOD ********************
require_once( $phpbb_root_path . 'chatspot_front.' . $phpEx );
// ********************  END phpBBChatSpot MOD  ********************
		'TOTAL_POSTS' => sprintf($l_total_post_s, $total_posts),
		'TOTAL_USERS' => sprintf($l_total_user_s, $total_users),
		'NEWEST_USER' => sprintf($lang['Newest_user'], '<a href="' . append_sid("profile.$phpEx?mode=viewprofile&" . POST_USERS_URL . "=$newest_uid") . '">', $newest_user, '</a>'),

		'FORUM_IMG' => $images['forum'],
		'FORUM_NEW_IMG' => $images['forum_new'],
		'FORUM_LOCKED_IMG' => $images['forum_locked'],

		'L_FORUM' => $lang['Forum'],
		'L_TOPICS' => $lang['Topics'],
		'L_REPLIES' => $lang['Replies'],
		'L_VIEWS' => $lang['Views'],
		'L_POSTS' => $lang['Posts'],
		'L_LASTPOST' => $lang['Last_Post'],
		'L_NO_NEW_POSTS' => $lang['No_new_posts'],
		'L_NEW_POSTS' => $lang['New_posts'],
		'L_NO_NEW_POSTS_LOCKED' => $lang['No_new_posts_locked'],
		'L_NEW_POSTS_LOCKED' => $lang['New_posts_locked'],
		'L_ONLINE_EXPLAIN' => $lang['Online_explain'],
Das sind alle Änderunge, die in der index.php gemacht werden sollten:

Code: Alles auswählen

#
#-----[ FIND ]---------------------------------------------
#
$template->assign_vars(array( 
'TOTAL_POSTS' => sprintf($l_total_post_s, $total_posts),

#
#-----[ BEFORE, ADD ]--------------------------------------
#
// ******************** BEGIN phpBBChatSpot MOD ********************
require_once( $phpbb_root_path . 'chatspot_front.' . $phpEx );
// ********************  END phpBBChatSpot MOD  ********************

#
#-----[ FIND ]---------------------------------------------
#
'L_MARK_FORUMS_READ' => $lang['Mark_all_forums'],

#
#-----[ AFTER, ADD ]--------------------------------------
#
// ******************** BEGIN phpBBChatSpot MOD ******************** 
'CHATSPOT_IDENTIFICATION' => $lang[ 'ChatSpot_id' ],
'TOTAL_CHATTERS_ONLINE' => sprintf( $lang[ 'How_Many_Chatters' ], $num_users_in_chat ),
'CHATTERS_LIST' => '<b>' . $users_in_chat . '</b>', 
'L_CLICK_TO_JOIN_CHAT' => $lang[ 'Click_to_join_chat' ],
//'S_JOIN_CHAT' => append_sid( "chatspot/chatspot.$phpEx" . "?initialize=1" ),
//'CHATSPOT_NAME' => 'Lobby', 
'L_LOGIN_TO_JOIN_CHAT' => $lang[ 'Login_to_join_chat' ],
// ********************  END phpBBChatSpot MOD  ********************

Verfasst: 03.10.2004 14:16
von Piet
Arrghhhh. Sehe grade das ich es falsch eingefügt habe. Ich teste es grade noch mal...

Getestet: geht jetzt soweit, shit wenn man blind ist...., danke aber für deine Hilfe :)

Verfasst: 03.10.2004 21:10
von Piet
Kennt jemand den Chat genauer? Weiß jemand, wie man das Timeout verändert, bis ein User rausgeschmissen wird?

Verfasst: 03.10.2004 21:14
von Supersonic
Kannst du in der chatspot_config.php einstellen.
'inactive_time' => '1200', // user's session is terminated after this long of inactivity (in seconds); 1200 = 20 minutes

Verfasst: 03.10.2004 21:31
von Piet
Ja, ich danke dir! Funzt! :)