Pagina 1 van 1
foutje bij instal mod
Geplaatst: 18 sep 2006, 18:30
door brambomb
hoi
ik krijg een foutje met deze mod: http://www.phpbbmods.nl/view.php?id=208
deze fout melding:Parse error: syntax error, unexpected T_VARIABLE in /home/bonobor/domains/bonobor.nl/public_html/forum/viewforum.php on line 372
het gaat om deze site:
http://www.bonobor.nl
dit is m'n vieuwforum.php waar het over gaat lijn 363 tot 381:
//
// User authorisation levels output
//
$s_auth_can = ( ( $is_auth['auth_post'] ) ? $lang['Rules_post_can'] : $lang['Rules_post_cannot'] ) . '<br />';
$s_auth_can .= ( ( $is_auth['auth_reply'] ) ? $lang['Rules_reply_can'] : $lang['Rules_reply_cannot'] ) . '<br />';
$s_auth_can .= ( ( $is_auth['auth_edit'] ) ? $lang['Rules_edit_can'] : $lang['Rules_edit_cannot'] ) . '<br />';
$s_auth_can .= ( ( $is_auth['auth_delete'] ) ? $lang['Rules_delete_can'] : $lang['Rules_delete_cannot'] ) . '<br />';
$s_auth_can .= ( ( $is_auth['auth_vote']
$s_auth_can .= ( $is_auth['auth_ban'] ) ? $lang['Rules_ban_can'] . '<br />' : '';
$s_auth_can .= ( $is_auth['auth_greencard'] ) ? $lang['Rules_greencard_can'] . '<br />' : '';
$s_auth_can .= ( $is_auth['auth_bluecard'] ) ? $lang['Rules_bluecard_can'] . '<br />' : '';
) ? $lang['Rules_vote_can'] : $lang['Rules_vote_cannot'] ) . '<br />';
if ( $is_auth['auth_mod'] )
{
$s_auth_can .= sprintf($lang['Rules_moderate'], "<a href=\"modcp.$phpEx?" . POST_FORUM_URL . "=$forum_id&start=" . $start . "&sid=" . $userdata['session_id'] . '">', '</a>');
}
wie kan mij helpen
Geplaatst: 18 sep 2006, 18:32
door Luuk
Code: Selecteer alles
$s_auth_can .= ( ( $is_auth['auth_vote']
$s_auth_can .= ( $is_auth['auth_ban'] ) ? $lang['Rules_ban_can'] . '<br />' : '';
$s_auth_can .= ( $is_auth['auth_greencard'] ) ? $lang['Rules_greencard_can'] . '<br />' : '';
$s_auth_can .= ( $is_auth['auth_bluecard'] ) ? $lang['Rules_bluecard_can'] . '<br />' : '';
) ? $lang['Rules_vote_can'] : $lang['Rules_vote_cannot'] ) . '<br />';
moet
Code: Selecteer alles
$s_auth_can .= ( ( $is_auth['auth_vote'] ) ? $lang['Rules_vote_can'] : $lang['Rules_vote_cannot'] ) . '<br />';
$s_auth_can .= ( $is_auth['auth_ban'] ) ? $lang['Rules_ban_can'] . '<br />' : '';
$s_auth_can .= ( $is_auth['auth_greencard'] ) ? $lang['Rules_greencard_can'] . '<br />' : '';
$s_auth_can .= ( $is_auth['auth_bluecard'] ) ? $lang['Rules_bluecard_can'] . '<br />' : '';
zijn
Geplaatst: 18 sep 2006, 19:32
door brambomb
dan krijg ik weer een fout melding alleen dan deze:
Parse error: syntax error, unexpected T_VARIABLE in /home/bonobor/domains/bonobor.nl/public_html/forum/viewtopic.php on line 587
en ook bij het admin gedeelte krijg ik een fout melding:
Parse error: syntax error, unexpected T_VARIABLE in /home/bonobor/domains/bonobor.nl/public_html/forum/admin/admin_users.php on line 310
Geplaatst: 18 sep 2006, 21:17
door Luuk
Post die stukken ook eens dan, je hebt waarschijnlijk de mod niet helemaal goed uitgevoerd

Geplaatst: 18 sep 2006, 21:34
door brambomb
viewtopic.php lijn 579 tot 606
//
// User authorisation levels output
//
$s_auth_can = ( ( $is_auth['auth_post'] ) ? $lang['Rules_post_can'] : $lang['Rules_post_cannot'] ) . '<br />';
$s_auth_can .= ( ( $is_auth['auth_reply'] ) ? $lang['Rules_reply_can'] : $lang['Rules_reply_cannot'] ) . '<br />';
$s_auth_can .= ( ( $is_auth['auth_edit'] ) ? $lang['Rules_edit_can'] : $lang['Rules_edit_cannot'] ) . '<br />';
$s_auth_can .= ( ( $is_auth['auth_delete'] ) ? $lang['Rules_delete_can'] : $lang['Rules_delete_cannot'] ) . '<br />';
$s_auth_can .= ( ( $is_auth['auth_vote']
$s_auth_can .= ( $is_auth['auth_ban'] ) ? $lang['Rules_ban_can'] . "<br />" : "";
$s_auth_can .= ( $is_auth['auth_greencard'] ) ? $lang['Rules_greencard_can'] . "<br />" : "";
$s_auth_can .= ( $is_auth['auth_bluecard'] ) ? $lang['Rules_bluecard_can'] . "<br />" : "";
) ? $lang['Rules_vote_can'] : $lang['Rules_vote_cannot'] ) . '<br />';
$topic_mod = '';
if ( $is_auth['auth_mod'] )
{
$s_auth_can .= sprintf($lang['Rules_moderate'], "<a href=\"modcp.$phpEx?" . POST_FORUM_URL . "=$forum_id&sid=" . $userdata['session_id'] . '">', '</a>');
$topic_mod .= "<a href=\"modcp.$phpEx?" . POST_TOPIC_URL . "=$topic_id&mode=delete&sid=" . $userdata['session_id'] . '"><img src="' . $images['topic_mod_delete'] . '" alt="' . $lang['Delete_topic'] . '" title="' . $lang['Delete_topic'] . '" border="0" /></a> ';
$topic_mod .= "<a href=\"modcp.$phpEx?" . POST_TOPIC_URL . "=$topic_id&mode=move&sid=" . $userdata['session_id'] . '"><img src="' . $images['topic_mod_move'] . '" alt="' . $lang['Move_topic'] . '" title="' . $lang['Move_topic'] . '" border="0" /></a> ';
$topic_mod .= ( $forum_topic_data['topic_status'] == TOPIC_UNLOCKED ) ? "<a href=\"modcp.$phpEx?" . POST_TOPIC_URL . "=$topic_id&mode=lock&sid=" . $userdata['session_id'] . '"><img src="' . $images['topic_mod_lock'] . '" alt="' . $lang['Lock_topic'] . '" title="' . $lang['Lock_topic'] . '" border="0" /></a> ' : "<a href=\"modcp.$phpEx?" . POST_TOPIC_URL . "=$topic_id&mode=unlock&sid=" . $userdata['session_id'] . '"><img src="' . $images['topic_mod_unlock'] . '" alt="' . $lang['Unlock_topic'] . '" title="' . $lang['Unlock_topic'] . '" border="0" /></a> ';
$topic_mod .= "<a href=\"modcp.$phpEx?" . POST_TOPIC_URL . "=$topic_id&mode=split&sid=" . $userdata['session_id'] . '"><img src="' . $images['topic_mod_split'] . '" alt="' . $lang['Split_topic'] . '" title="' . $lang['Split_topic'] . '" border="0" /></a> ';
}
en admin/admin_users.php lijn 300 tot 316
$user_avatar_remoteurl = ( !empty($HTTP_POST_VARS['avatarremoteurl']) ) ? trim( $HTTP_POST_VARS['avatarremoteurl'] ) : '';
$user_avatar_url = ( !empty($HTTP_POST_VARS['avatarurl']) ) ? trim( $HTTP_POST_VARS['avatarurl'] ) : '';
$user_avatar_loc = ( $HTTP_POST_FILES['avatar']['tmp_name'] != "none") ? $HTTP_POST_FILES['avatar']['tmp_name'] : '';
$user_avatar_name = ( !empty($HTTP_POST_FILES['avatar']['name']) ) ? $HTTP_POST_FILES['avatar']['name'] : '';
$user_avatar_size = ( !empty($HTTP_POST_FILES['avatar']['size']) ) ? $HTTP_POST_FILES['avatar']['size'] : 0;
$user_avatar_filetype = ( !empty($HTTP_POST_FILES['avatar']['type']) ) ? $HTTP_POST_FILES['avatar']['type'] : '';
$user_avatar = ( empty($user_avatar_loc) ) ? $this_userdata['user_avatar'] : '';
$user_avatar_type = ( empty($user_avatar_loc) ) ? $this_userdata['user_avatar_type'] : '';
$user_status = ( !empty($HTTP_POST_VARS['user_status']) )$user_ycard = ( !empty($HTTP_POST_VARS['user_ycard']) ) ? intval( $HTTP_POST_VARS['user_ycard'] ) : 0; ? intval( $HTTP_POST_VARS['user_status'] ) : 0;
$user_allowpm = ( !empty($HTTP_POST_VARS['user_allowpm']) ) ? intval( $HTTP_POST_VARS['user_allowpm'] ) : 0;
$user_rank = ( !empty($HTTP_POST_VARS['user_rank']) ) ? intval( $HTTP_POST_VARS['user_rank'] ) : 0;
$user_allowavatar = ( !empty($HTTP_POST_VARS['user_allowavatar']) ) ? intval( $HTTP_POST_VARS['user_allowavatar'] ) : 0;
if( isset( $HTTP_POST_VARS['avatargallery'] ) || isset( $HTTP_POST_VARS['submitavatar'] ) || isset( $HTTP_POST_VARS['cancelavatar'] ) )
{
Geplaatst: 18 sep 2006, 21:41
door Luuk
Code: Selecteer alles
$s_auth_can .= ( ( $is_auth['auth_vote']
$s_auth_can .= ( $is_auth['auth_ban'] ) ? $lang['Rules_ban_can'] . "<br />" : "";
$s_auth_can .= ( $is_auth['auth_greencard'] ) ? $lang['Rules_greencard_can'] . "<br />" : "";
$s_auth_can .= ( $is_auth['auth_bluecard'] ) ? $lang['Rules_bluecard_can'] . "<br />" : "";
) ? $lang['Rules_vote_can'] : $lang['Rules_vote_cannot'] ) . '<br />';
wordt
Code: Selecteer alles
$s_auth_can .= ( ( $is_auth['auth_vote']) ? $lang['Rules_vote_can'] : $lang['Rules_vote_cannot'] ) . '<br />';
$s_auth_can .= ( $is_auth['auth_ban'] ) ? $lang['Rules_ban_can'] . "<br />" : "";
$s_auth_can .= ( $is_auth['auth_greencard'] ) ? $lang['Rules_greencard_can'] . "<br />" : "";
$s_auth_can .= ( $is_auth['auth_bluecard'] ) ? $lang['Rules_bluecard_can'] . "<br />" : "";
en
Code: Selecteer alles
$user_status = ( !empty($HTTP_POST_VARS['user_status']) )$user_ycard = ( !empty($HTTP_POST_VARS['user_ycard']) ) ? intval( $HTTP_POST_VARS['user_ycard'] ) : 0; ? intval( $HTTP_POST_VARS['user_status'] ) : 0;
wordt
Code: Selecteer alles
$user_status = ( !empty($HTTP_POST_VARS['user_status']) ) ? intval( $HTTP_POST_VARS['user_status'] ) : 0;
$user_ycard = ( !empty($HTTP_POST_VARS['user_ycard']) ) ? intval( $HTTP_POST_VARS['user_ycard'] ) : 0;
Geplaatst: 18 sep 2006, 21:50
door brambomb
yeah ik kan nu al wel het topic zien alleen zit er nog iets niet goed
kijk maar eens naar dit topic
http://www.forum.bonobor.nl/viewtopic.php?t=13
ook nog deze fout bij admin:
Parse error: syntax error, unexpected T_DOUBLE_ARROW in /home/bonobor/domains/bonobor.nl/public_html/forum/admin/admin_ug_auth.php on line 147
//
// Get group_id for this user_id
//
$sql = "SELECT g.group_id, u.user_level
FROM " . USER_GROUP_TABLE . " ug, " . USERS_TABLE . " u, " . GROUPS_TABLE . " g
WHERE u.user_id = $user_id
AND ug.user_id = u.user_id
AND g.group_id = ug.group_id
AND g.group_single_user = " . TRUE;
if ( !($result = $db->sql_query($sql)) )
{
message_die(GENERAL_ERROR, 'Could not select info from user/user_group table', '', __LINE__, __FILE__, $sql,
'auth_ban' => AUTH_BAN,
'auth_greencard' => AUTH_GREENCARD,
'auth_bluecard' => AUTH_BLUECARD);
}
$row = $db->sql_fetchrow($result);
$group_id = $row['group_id'];
$user_level = $row['user_level'];
$db->sql_freeresult($result);
}
Geplaatst: 18 sep 2006, 21:57
door Luuk
Lees dit artikel (nog) eens door, je hebt het modden niet helemaal goed gesnapt:
http://www.phpbb.nl/kb.php?mode=article&k=24
templates/xxx/viewtopic_body.tpl klopt helemaal niet. Je bent waarschijnlijk iets te letterlijk met zoeken, je moet normaal na/voor de hele regel wat je zoekt iets toevoegen. Of het moet duidelijk erbij staan, IN-LINE ADD.

Geplaatst: 18 sep 2006, 21:58
door brambomb
oke

alsnog bedankt
ik voel me best wel een noob

Geplaatst: 18 sep 2006, 22:01
door Luuk
Iedereen is begonnen bij niks, dus fouten maken mag heel zeker! Doe het nu nog steeds dusja...

Geplaatst: 18 sep 2006, 22:18
door brambomb
het is gelukt met het post gedeelte alleen bij de admin wil het nog niet lukken kun je me daar mee helpen
#-----[ FIND ]------------------------------------------------
#
);
#
#-----[ IN-LINE FIND ]----------------------------------------
#
);
#
#-----[ IN-LINE REPLACE WITH ]--------------------------------
#
,
#
#-----[ AFTER, ADD ]------------------------------------------
#
'auth_ban' => AUTH_BAN,
'auth_greencard' => AUTH_GREENCARD,
'auth_bluecard' => AUTH_BLUECARD);
dit is wat er op lijn 147 staat. dit was wat ik daar heb ingevult maar alleen omdat er zoveel ); enzo zijn en niet in dezelfde lijn snap ik er geen bal meer van
kan iemand mij helpen met instaleren als ik ff het ftpwachtwoord geef enzo
Geplaatst: 19 sep 2006, 14:14
door Luuk
Je hebt het stuk vergeten te posten, het stuk is waarschijnlijk iets als
Code: Selecteer alles
$template->assign_vars(array(
'VAR_1' => $var_1,
'VAR_2' => $var_2)
);
dat wordt dan
Code: Selecteer alles
$template->assign_vars(array(
'VAR_1' => $var_1,
'VAR_2' => $var_2,
'auth_ban' => AUTH_BAN,
'auth_greencard' => AUTH_GREENCARD,
'auth_bluecard' => AUTH_BLUECARD)
);
Geplaatst: 19 sep 2006, 15:04
door brambomb
ik snap er geen bal meer van

Geplaatst: 19 sep 2006, 15:11
door Luuk
Post die regels rond 147 eens

Geplaatst: 19 sep 2006, 15:19
door brambomb
dit is regel 140 tot 160
WHERE u.user_id = $user_id
AND ug.user_id = u.user_id
AND g.group_id = ug.group_id
AND g.group_single_user = " . TRUE;
if ( !($result = $db->sql_query($sql)) )
{
message_die(GENERAL_ERROR, 'Could not select info from user/user_group table', '', __LINE__, __FILE__, $sql,
$template->assign_vars(array(
'VAR_1' => $var_1,
'VAR_2' => $var_2,
'auth_ban' => AUTH_BAN,
'auth_greencard' => AUTH_GREENCARD,
'auth_bluecard' => AUTH_BLUECARD)
);
}
$row = $db->sql_fetchrow($result);
edit: ik heb je op msn toegevoegt
Geplaatst: 19 sep 2006, 15:26
door Luuk
Je moet het er ook niet neetzetten, het was een voorbeeld.
Op die plek moet het zeker niet neerzetten, zover ik kan zien moet je in admin/ug_auth.php zijn,
wordt
Code: Selecteer alles
'auth_pollcreate' => AUTH_POLLCREATE,
'auth_ban' => AUTH_BAN,
'auth_greencard' => AUTH_GREENCARD,
'auth_bluecard' => AUTH_BLUECARD);
Geplaatst: 19 sep 2006, 16:31
door brambomb
luuk hartstikke bedankt :thumb: