Bug bij Registreren

Installatie lukt niet? Plotseling een foutmelding. Of weet je niet hoe iets werkt. Problemen met phpBB2 kun je in dit archief opzoeken.
Forumregels

Sinds 1 januari 2009 wordt phpBB2 niet meer ondersteund.
Onderstaande informatie is verouderd en dient uitsluitend als archief.
phpBB2.0.x
Gebruikersavatar
hotrid
Berichten: 452
Lid geworden op: 24 jun 2003, 14:33
Locatie: Almelo
Contacteer:

Bug bij Registreren

Bericht door hotrid » 04 jan 2004, 02:13

Heb een veld toegevoegd aan me profiel, maar wanneer iemand zich registreerd krijg je een foutmelding in de db :
Could not insert data into users table

DEBUG MODE

SQL Error : 1064 You have an error in your SQL syntax near ' 1, 'd F Y G:i', 'dutch', 2, 0, 1, '999999', '',1, '')' at line 2

INSERT INTO phpbb_users (user_id, username, user_regdate, user_password, user_email, user_icq, user_website, user_occ, user_from, user_interests, user_music, user_sig, user_sig_bbcode_uid, user_avatar, user_avatar_type, user_viewemail, user_aim, user_yim, user_msnm, user_attachsig, user_allowsmile, user_allowhtml, user_allowbbcode, user_allow_viewonline, user_notify, user_notify_pm, user_popup_pm, user_timezone, user_dateformat, user_lang, user_style, user_level, user_allow_pm, user_active, user_actkey) VALUES (144, 'ts', 1073179426, '', 'tw@hotmail.com', '', '', '', '', '', '', '', '', '', 0, 0, '', '', '', 1, 1, 0, 1, 1, 0, 1, , 1, 'd F Y G:i', 'dutch', 2, 0, 1, '999999', '',1, '')

Line : 594
File : /home/virtual/site19/fst/var/www/html/forum/includes/usercp_register.php
In het stukje van usercp_register.php is niets fout.... :roll:
Laatst gewijzigd door hotrid op 05 jan 2004, 14:12, 1 keer totaal gewijzigd.

Gebruikersavatar
WebSiteNet
Berichten: 6524
Lid geworden op: 20 okt 2003, 16:56
Locatie: Wieringerwerf
Contacteer:

Bericht door WebSiteNet » 04 jan 2004, 13:39

Could not insert data into users table

DEBUG MODE

SQL Error : 1064 You have an error in your SQL syntax near ' 1, 'd F Y G:i', 'dutch', 2, 0, 1, '999999', '',1, '')' at line 2

INSERT INTO phpbb_users (user_id, username, user_regdate, user_password, user_email, user_icq, user_website, user_occ, user_from, user_interests, user_music, user_sig, user_sig_bbcode_uid, user_avatar, user_avatar_type, user_viewemail, user_aim, user_yim, user_msnm, user_attachsig, user_allowsmile, user_allowhtml, user_allowbbcode, user_allow_viewonline, user_notify, user_notify_pm, user_popup_pm, user_timezone, user_dateformat, user_lang, user_style, user_level, user_allow_pm, user_active, user_actkey) VALUES (144, 'ts', 1073179426, '', 'tw@hotmail.com', '', '', '', '', '', '', '', '', '', 0, 0, '', '', '', 1, 1, 0, 1, 1, 0, 1, , 1, 'd F Y G:i', 'dutch', 2, 0, 1, '999999', '',1, '')

Line : 594
File : /home/virtual/site19/fst/var/www/html/forum/includes/usercp_register.php
Leeg veld is niet zo handig. of daar moet 0 stan of ''.

Gebruikersavatar
hotrid
Berichten: 452
Lid geworden op: 24 jun 2003, 14:33
Locatie: Almelo
Contacteer:

Bericht door hotrid » 04 jan 2004, 14:28

Hoe los ik dit op dan :oops:

Gebruikersavatar
Luuk
Berichten: 7311
Lid geworden op: 22 okt 2003, 10:07
Locatie: Delft

Bericht door Luuk » 04 jan 2004, 14:56

Code: Selecteer alles

1, ", 1,
misschien :roll:
Afbeelding

Gebruikersavatar
hotrid
Berichten: 452
Lid geworden op: 24 jun 2003, 14:33
Locatie: Almelo
Contacteer:

Bericht door hotrid » 04 jan 2004, 15:10

Zover was ik ook al, maar waar

Gebruikersavatar
Luuk
Berichten: 7311
Lid geworden op: 22 okt 2003, 10:07
Locatie: Delft

Bericht door Luuk » 04 jan 2004, 15:12

In includes/usercp_register.php rond lijn 594 :roll:
Afbeelding

Gebruikersavatar
hotrid
Berichten: 452
Lid geworden op: 24 jun 2003, 14:33
Locatie: Almelo
Contacteer:

Bericht door hotrid » 04 jan 2004, 15:20

//
// Get current date
//
$sql = "INSERT INTO " . USERS_TABLE . " (user_id, username, user_regdate, user_password, user_email, user_icq, user_website, user_occ, user_from, user_interests, user_music, user_sig, user_sig_bbcode_uid, user_avatar, user_avatar_type, user_viewemail, user_aim, user_yim, user_msnm, user_attachsig, user_allowsmile, user_allowhtml, user_allowbbcode, user_allow_viewonline, user_notify, user_notify_pm, user_popup_pm, user_timezone, user_dateformat, user_lang, user_style, user_level, user_allow_pm, user_active, user_actkey)
VALUES ($user_id, '" . str_replace("\'", "''", $username) . "', " . time() . ", '" . str_replace("\'", "''", $password) . "', '" . str_replace("\'", "''", $email) . "', '" . str_replace("\'", "''", $icq) . "', '" . str_replace("\'", "''", $website) . "', '" . str_replace("\'", "''", $occupation) . "', '" . str_replace("\'", "''", $location) . "', '" . str_replace("\'", "''", $interests) . "', '" . str_replace("\'", "''", $music) . "', '" . str_replace("\'", "''", $signature) . "', '$signature_bbcode_uid', $avatar_sql, $viewemail, '" . str_replace("\'", "''", str_replace(' ', '+', $aim)) . "', '" . str_replace("\'", "''", $yim) . "', '" . str_replace("\'", "''", $msn) . "', $attachsig, $allowsmilies, $allowhtml, $allowbbcode, $allowviewonline, $notifyreply, $notifypm, $popuppm, $user_timezone, '" . str_replace("\'", "''", $user_dateformat) . "', '" . str_replace("\'", "''", $user_lang) . "', $user_style, 0, 1, '$birthday', '$next_birthday_greeting',";
if ( $board_config['require_activation'] == USER_ACTIVATION_SELF || $board_config['require_activation'] == USER_ACTIVATION_ADMIN || $coppa )
{
$user_actkey = gen_rand_string(true);
$key_len = 54 - (strlen($server_url));
$key_len = ( $key_len > 6 ) ? $key_len : 6;
$user_actkey = substr($user_actkey, 0, $key_len);
$sql .= "0, '" . str_replace("\'", "''", $user_actkey) . "')";
}
else
{
$sql .= "1, '')";
}

if ( !($result = $db->sql_query($sql, BEGIN_TRANSACTION)) )
{
(REGEL 594)message_die(GENERAL_ERROR, 'Could not insert data into users table', '', __LINE__, __FILE__, $sql);
}

$sql = "INSERT INTO " . GROUPS_TABLE . " (group_name, group_description, group_single_user, group_moderator)
VALUES ('', 'Personal User', 1, 0)";
if ( !($result = $db->sql_query($sql)) )
{
message_die(GENERAL_ERROR, 'Could not insert data into groups table', '', __LINE__, __FILE__, $sql);
}

$group_id = $db->sql_nextid();

$sql = "INSERT INTO " . USER_GROUP_TABLE . " (user_id, group_id, user_pending)
VALUES ($user_id, $group_id, 0)";
if( !($result = $db->sql_query($sql, END_TRANSACTION)) )
{
message_die(GENERAL_ERROR, 'Could not insert data into user_group table', '', __LINE__, __FILE__, $sql);
}

if ( $coppa )
{
$message = $lang['COPPA'];
$email_template = 'coppa_welcome_inactive';
}
else if ( $board_config['require_activation'] == USER_ACTIVATION_SELF )
{
$message = $lang['Account_inactive'];
$email_template = 'user_welcome_inactive';
}
else if ( $board_config['require_activation'] == USER_ACTIVATION_ADMIN )
{
$message = $lang['Account_inactive_admin'];
$email_template = 'admin_welcome_inactive';
}
else
{
$message = $lang['Account_added'];
$email_template = 'user_welcome';
}

include($phpbb_root_path . 'includes/em
Hier heb je het dan :roll:

Gebruikersavatar
Luuk
Berichten: 7311
Lid geworden op: 22 okt 2003, 10:07
Locatie: Delft

Bericht door Luuk » 04 jan 2004, 15:31

Laat alles een zien
Afbeelding

Gebruikersavatar
hotrid
Berichten: 452
Lid geworden op: 24 jun 2003, 14:33
Locatie: Almelo
Contacteer:

Bericht door hotrid » 04 jan 2004, 15:33

Hoe bedoel je ? Laat alles eens zien (de hele usercp_register.php)

Gebruikersavatar
Luuk
Berichten: 7311
Lid geworden op: 22 okt 2003, 10:07
Locatie: Delft

Bericht door Luuk » 04 jan 2004, 16:01

OK, mij lijkt me

Code: Selecteer alles

'$next_birthday_greeting',";
niet in orde. De hele zooi wordt wel geopent met een , maar NIET afgesloten. Misschien is dit dan goed

Code: Selecteer alles

'$next_birthday_greeting',";)
Dat wordt dus dit:

//EDIT: zie volgende post, het past er niet helemaal op.
//EDIT 2: Daar past het ook niet helemaal erop, in het voorbeeld zie ik wel alles. Het staat hier: http://luukw.50free.org/blaat.txt
Afbeelding

Gebruikersavatar
hotrid
Berichten: 452
Lid geworden op: 24 jun 2003, 14:33
Locatie: Almelo
Contacteer:

Bericht door hotrid » 04 jan 2004, 16:14

Wanneer ik dat heb gedaan staat er
Parse error: parse error in /home/virtual/site19/fst/var/www/html/forum/includes/usercp_register.php on line 578
hier is het stukje met regel 578

Code: Selecteer alles

// 
// Get current date 
// 
$sql = "INSERT INTO " . USERS_TABLE . " (user_id, username, user_regdate, user_password, user_email, user_icq, user_website, user_occ, user_from, user_interests, user_music, user_sig, user_sig_bbcode_uid, user_avatar, user_avatar_type, user_viewemail, user_aim, user_yim, user_msnm, user_attachsig, user_allowsmile, user_allowhtml, user_allowbbcode, user_allow_viewonline, user_notify, user_notify_pm, user_popup_pm, user_timezone, user_dateformat, user_lang, user_style, user_level, user_allow_pm, user_active, user_actkey) 
VALUES ($user_id, '" . str_replace("\'", "''", $username) . "', " . time() . ", '" . str_replace("\'", "''", $password) . "', '" . str_replace("\'", "''", $email) . "', '" . str_replace("\'", "''", $icq) . "', '" . str_replace("\'", "''", $website) . "', '" . str_replace("\'", "''", $occupation) . "', '" . str_replace("\'", "''", $location) . "', '" . str_replace("\'", "''", $interests) . "', '" . str_replace("\'", "''", $music) . "', '" . str_replace("\'", "''", $signature) . "', '$signature_bbcode_uid', $avatar_sql, $viewemail, '" . str_replace("\'", "''", str_replace(' ', '+', $aim)) . "', '" . str_replace("\'", "''", $yim) . "', '" . str_replace("\'", "''", $msn) . "', $attachsig, $allowsmilies, $allowhtml, $allowbbcode, $allowviewonline, $notifyreply, $notifypm, $popuppm, $user_timezone, '" . str_replace("\'", "''", $user_dateformat) . "', '" . str_replace("\'", "''", $user_lang) . "', $user_style, 0, 1, '$birthday', '$next_birthday_greeting',";) 
if ( $board_config['require_activation'] == USER_ACTIVATION_SELF || $board_config['require_activation'] == USER_ACTIVATION_ADMIN || $coppa ) 
{ 

Gebruikersavatar
Luuk
Berichten: 7311
Lid geworden op: 22 okt 2003, 10:07
Locatie: Delft

Bericht door Luuk » 04 jan 2004, 16:17

Code: Selecteer alles

// 
// Get current date 
// 
$sql = "INSERT INTO " . USERS_TABLE . " (user_id, username, user_regdate, user_password, user_email, user_icq, user_website, user_occ, user_from, user_interests, user_music, user_sig, user_sig_bbcode_uid, user_avatar, user_avatar_type, user_viewemail, user_aim, user_yim, user_msnm, user_attachsig, user_allowsmile, user_allowhtml, user_allowbbcode, user_allow_viewonline, user_notify, user_notify_pm, user_popup_pm, user_timezone, user_dateformat, user_lang, user_style, user_level, user_allow_pm, user_active, user_actkey) 
VALUES ($user_id, '" . str_replace("\'", "''", $username) . "', " . time() . ", '" . str_replace("\'", "''", $password) . "', '" . str_replace("\'", "''", $email) . "', '" . str_replace("\'", "''", $icq) . "', '" . str_replace("\'", "''", $website) . "', '" . str_replace("\'", "''", $occupation) . "', '" . str_replace("\'", "''", $location) . "', '" . str_replace("\'", "''", $interests) . "', '" . str_replace("\'", "''", $music) . "', '" . str_replace("\'", "''", $signature) . "', '$signature_bbcode_uid', $avatar_sql, $viewemail, '" . str_replace("\'", "''", str_replace(' ', '+', $aim)) . "', '" . str_replace("\'", "''", $yim) . "', '" . str_replace("\'", "''", $msn) . "', $attachsig, $allowsmilies, $allowhtml, $allowbbcode, $allowviewonline, $notifyreply, $notifypm, $popuppm, $user_timezone, '" . str_replace("\'", "''", $user_dateformat) . "', '" . str_replace("\'", "''", $user_lang) . "', $user_style, 0, 1, '$birthday', '$next_birthday_greeting' ;) 
if ( $board_config['require_activation'] == USER_ACTIVATION_SELF || $board_config['require_activation'] == USER_ACTIVATION_ADMIN || $coppa ) 
{ 
En zo dan?
Afbeelding

Gebruikersavatar
hotrid
Berichten: 452
Lid geworden op: 24 jun 2003, 14:33
Locatie: Almelo
Contacteer:

Bericht door hotrid » 04 jan 2004, 16:22

dan krijg je

Code: Selecteer alles

Parse error: parse error, expecting `T_STRING' or `T_VARIABLE' or `T_NUM_STRING' in /home/virtual/site19/fst/var/www/html/forum/includes/usercp_register.php on line 579

Gebruikersavatar
Luuk
Berichten: 7311
Lid geworden op: 22 okt 2003, 10:07
Locatie: Delft

Bericht door Luuk » 04 jan 2004, 16:27

Probeer dan of dit:

Code: Selecteer alles

// 
// Get current date 
// 
$sql = "INSERT INTO " . USERS_TABLE . " (user_id, username, user_regdate, user_password, user_email, user_icq, user_website, user_occ, user_from, user_interests, user_music, user_sig, user_sig_bbcode_uid, user_avatar, user_avatar_type, user_viewemail, user_aim, user_yim, user_msnm, user_attachsig, user_allowsmile, user_allowhtml, user_allowbbcode, user_allow_viewonline, user_notify, user_notify_pm, user_popup_pm, user_timezone, user_dateformat, user_lang, user_style, user_level, user_allow_pm, user_active, user_actkey) 
VALUES ($user_id, '" . str_replace("\'", "''", $username) . "', " . time() . ", '" . str_replace("\'", "''", $password) . "', '" . str_replace("\'", "''", $email) . "', '" . str_replace("\'", "''", $icq) . "', '" . str_replace("\'", "''", $website) . "', '" . str_replace("\'", "''", $occupation) . "', '" . str_replace("\'", "''", $location) . "', '" . str_replace("\'", "''", $interests) . "', '" . str_replace("\'", "''", $music) . "', '" . str_replace("\'", "''", $signature) . "', '$signature_bbcode_uid', $avatar_sql, $viewemail, '" . str_replace("\'", "''", str_replace(' ', '+', $aim)) . "', '" . str_replace("\'", "''", $yim) . "', '" . str_replace("\'", "''", $msn) . "', $attachsig, $allowsmilies, $allowhtml, $allowbbcode, $allowviewonline, $notifyreply, $notifypm, $popuppm, $user_timezone, '" . str_replace("\'", "''", $user_dateformat) . "', '" . str_replace("\'", "''", $user_lang) . "', $user_style, '$birthday', '$next_birthday_greeting', 0, 1, ";
if ( $board_config['require_activation'] == USER_ACTIVATION_SELF || $board_config['require_activation'] == USER_ACTIVATION_ADMIN || $coppa ) 
{ 
En als dat niet lukt dit:

Code: Selecteer alles

// 
// Get current date 
// 
$sql = "INSERT INTO " . USERS_TABLE . " (user_id, username, user_regdate, user_password, user_email, user_icq, user_website, user_occ, user_from, user_interests, user_music, user_sig, user_sig_bbcode_uid, user_avatar, user_avatar_type, user_viewemail, user_aim, user_yim, user_msnm, user_attachsig, user_allowsmile, user_allowhtml, user_allowbbcode, user_allow_viewonline, user_notify, user_notify_pm, user_popup_pm, user_timezone, user_dateformat, user_lang, user_style, user_level, user_allow_pm, user_active, user_actkey) 
VALUES ($user_id, '" . str_replace("\'", "''", $username) . "', " . time() . ", '" . str_replace("\'", "''", $password) . "', '" . str_replace("\'", "''", $email) . "', '" . str_replace("\'", "''", $icq) . "', '" . str_replace("\'", "''", $website) . "', '" . str_replace("\'", "''", $occupation) . "', '" . str_replace("\'", "''", $location) . "', '" . str_replace("\'", "''", $interests) . "', '" . str_replace("\'", "''", $music) . "', '" . str_replace("\'", "''", $signature) . "', '$signature_bbcode_uid', $avatar_sql, $viewemail, '" . str_replace("\'", "''", str_replace(' ', '+', $aim)) . "', '" . str_replace("\'", "''", $yim) . "', '" . str_replace("\'", "''", $msn) . "', $attachsig, $allowsmilies, $allowhtml, $allowbbcode, $allowviewonline, $notifyreply, $notifypm, $popuppm, $user_timezone, '" . str_replace("\'", "''", $user_dateformat) . "', '" . str_replace("\'", "''", $user_lang) . "', $user_style, $birthday, $next_birthday_greeting, 0, 1, ";
if ( $board_config['require_activation'] == USER_ACTIVATION_SELF || $board_config['require_activation'] == USER_ACTIVATION_ADMIN || $coppa ) 
{ 
Afbeelding

Gebruikersavatar
hotrid
Berichten: 452
Lid geworden op: 24 jun 2003, 14:33
Locatie: Almelo
Contacteer:

Bericht door hotrid » 04 jan 2004, 16:30

We zijn weer vanaf begin af aan =->
Could not update users table

DEBUG MODE

SQL Error : 1064 You have an error in your SQL syntax near ' user_timezone = 1, user_dateformat = 'd F Y G:i', user_lang = 'dutch', user_sty' at line 2

UPDATE phpbb_users SET user_email = 'hotrid@hotmail.com', user_icq = '', user_website = 'http://www.hotrid.nl/forum/', user_occ = 'Student enzo', user_from = 'Almelos', user_interests = 'Beheerder van http://www.hotrid.nl', user_music = 'Trance, Dance, Techno & Rock', user_sig = 'Forum Verpest het niet', user_sig_bbcode_uid = 'c7f1a3d259', user_viewemail = 1, user_aim = '', user_yim = '', user_msnm = 'hotrid@hotmail.com', user_attachsig = 1, user_allowsmile = 1, user_allowhtml = 1, user_allowbbcode = 1, user_allow_viewonline = 1, user_notify = 0, user_notify_pm = 0, user_popup_pm = , user_timezone = 1, user_dateformat = 'd F Y G:i', user_lang = 'dutch', user_style = 2, user_active = 1, user_actkey = '' WHERE user_id = 2

Line : 518
File : /home/virtual/site19/fst/var/www/html/forum/includes/usercp_register.php

user_popup_pm =

Staat niets ingevuld....
Laatst gewijzigd door hotrid op 04 jan 2004, 16:31, 1 keer totaal gewijzigd.

Gebruikersavatar
Luuk
Berichten: 7311
Lid geworden op: 22 okt 2003, 10:07
Locatie: Delft

Bericht door Luuk » 04 jan 2004, 16:31

Ook bij de tweede?
Afbeelding

Gebruikersavatar
hotrid
Berichten: 452
Lid geworden op: 24 jun 2003, 14:33
Locatie: Almelo
Contacteer:

Bericht door hotrid » 04 jan 2004, 16:31

Ja


Weet niemand het :?

Gebruikersavatar
hotrid
Berichten: 452
Lid geworden op: 24 jun 2003, 14:33
Locatie: Almelo
Contacteer:

Bericht door hotrid » 04 jan 2004, 17:35

Komt doro de mod die ik het laatst heb gedaan hierbij moest ik het volgende wijzigen :

#

Code: Selecteer alles

 
#-----[ OPEN ]------------------------------------------ 
#  
# includes/usercp_register.php
# 
#-----[ FIND ]---------------------------------------------------
# 
	$strip_var_list = array('username' => 'username', 'email' => 'email', 'icq' => 'icq', 'aim' => 'aim', 'msn' => 'msn', 'yim' => 'yim', 'website' => 'website', 'location' => 'location', 'occupation' => 'occupation', 'interests' => 'interests');

# 
#-----[ IN-LINE FIND ]---------------------------------------------------
# 
'interests'

# 
#-----[ IN-LINE ADD ]---------------------------------------------------
# 
, 'music' => 'music'

# 
#-----[ FIND ]---------------------------------------------------
# 
	validate_optional_fields($icq, $aim, $msn, $yim, $website, $location, $occupation, $interests, $signature);

# 
#-----[ IN-LINE FIND ]---------------------------------------------------
# 
$interests

# 
#-----[ IN-LINE ADD ]---------------------------------------------------
# 
, $music

# 
#-----[ FIND (1st occurence) ]---------------------------------------------------
# 
		$interests = stripslashes($interests);

# 
#-----[ ADD BELOW ]---------------------------------------------------
# 
		$music = stripslashes($music);

# 
#-----[ FIND ]---------------------------------------------------
# 
			$sql = "UPDATE " . USERS_TABLE . "
				SET " . $username_sql . $passwd_sql . "user_email = '" . str_replace("\'", "''", $email) ."', user_icq = '" . str_replace("\'", "''", $icq) . "', user_website = '" . str_replace("\'", "''", $website) . "', user_occ = '" . str_replace("\'", "''", $occupation) . "', user_from = '" . str_replace("\'", "''", $location) . "', user_interests = '" . str_replace("\'", "''", $interests) . "', user_sig = '" . str_replace("\'", "''", $signature) . "', user_sig_bbcode_uid = '$signature_bbcode_uid', user_viewemail = $viewemail, user_aim = '" . str_replace("\'", "''", str_replace(' ', '+', $aim)) . "', user_yim = '" . str_replace("\'", "''", $yim) . "', user_msnm = '" . str_replace("\'", "''", $msn) . "', user_attachsig = $attachsig, user_allowsmile = $allowsmilies, user_allowhtml = $allowhtml, user_allowbbcode = $allowbbcode, user_allow_viewonline = $allowviewonline, user_notify = $notifyreply, user_notify_pm = $notifypm, user_popup_pm = $popuppm, user_timezone = $user_timezone, user_dateformat = '" . str_replace("\'", "''", $user_dateformat) . "', user_lang = '" . str_replace("\'", "''", $user_lang) . "', user_style = $user_style, user_active = $user_active, user_actkey = '" . str_replace("\'", "''", $user_actkey) . "'" . $avatar_sql . "

# 
#-----[ IN-LINE FIND ]---------------------------------------------------
# 
$interests) . "'

# 
#-----[ IN-LINE ADD ]---------------------------------------------------
# 
, user_music = '" . str_replace("\'", "''", $music) . "'

# 
#-----[ FIND ]---------------------------------------------------
# 
			$sql = "INSERT INTO " . USERS_TABLE . "	(user_id, username, user_regdate, user_password, user_email, user_icq, user_website, user_occ, user_from, user_interests, user_sig, user_sig_bbcode_uid, user_avatar, user_avatar_type, user_viewemail, user_aim, user_yim, user_msnm, user_attachsig, user_allowsmile, user_allowhtml, user_allowbbcode, user_allow_viewonline, user_notify, user_notify_pm, user_popup_pm, user_timezone, user_dateformat, user_lang, user_style, user_level, user_allow_pm, user_active, user_actkey)
				VALUES ($user_id, '" . str_replace("\'", "''", $username) . "', " . time() . ", '" . str_replace("\'", "''", $password) . "', '" . str_replace("\'", "''", $email) . "', '" . str_replace("\'", "''", $icq) . "', '" . str_replace("\'", "''", $website) . "', '" . str_replace("\'", "''", $occupation) . "', '" . str_replace("\'", "''", $location) . "', '" . str_replace("\'", "''", $interests) . "', '" . str_replace("\'", "''", $signature) . "', '$signature_bbcode_uid', $avatar_sql, $viewemail, '" . str_replace("\'", "''", str_replace(' ', '+', $aim)) . "', '" . str_replace("\'", "''", $yim) . "', '" . str_replace("\'", "''", $msn) . "', $attachsig, $allowsmilies, $allowhtml, $allowbbcode, $allowviewonline, $notifyreply, $notifypm, $popuppm, $user_timezone, '" . str_replace("\'", "''", $user_dateformat) . "', '" . str_replace("\'", "''", $user_lang) . "', $user_style, 0, 1, ";

# 
#-----[ IN-LINE FIND ]---------------------------------------------------
# 
user_interests

# 
#-----[ IN-LINE ADD ]---------------------------------------------------
# 
, user_music

# 
#-----[ IN-LINE FIND ]---------------------------------------------------
# 
$interests) . "'

# 
#-----[ IN-LINE ADD ]---------------------------------------------------
# 
, '" . str_replace("\'", "''", $music) . "'

# 
#-----[ FIND (2nd occurence) ]---------------------------------------------------
# 
	$interests = stripslashes($interests);

# 
#-----[ ADD BELOW ]---------------------------------------------------
# 
	$music = stripslashes($music);

# 
#-----[ FIND ]---------------------------------------------------
# 
	$interests = $userdata['user_interests'];

# 
#-----[ ADD BELOW ]---------------------------------------------------
# 
	$music = $userdata['user_music'];

# 
#-----[ FIND ]---------------------------------------------------
# 
display_avatar_gallery($mode, $avatar_category, $user_id, $email, $current_email, $coppa, $username, $email, &$new_password, &$cur_password, $password_confirm, $icq, $aim, $msn, $yim, $website, $location, $occupation, $interests, $signature, $viewemail, $notifypm, $popuppm, $notifyreply, $attachsig, $allowhtml, $allowbbcode, $allowsmilies, $allowviewonline, $user_style, $user_lang, $user_timezone, $user_dateformat, $userdata['session_id']);

# 
#-----[ IN-LINE FIND ]---------------------------------------------------
# 
$user_dateformat

# 
#-----[ IN-LINE ADD ]---------------------------------------------------
# 
, $music

# 
#-----[ FIND (just a quote) ]--------------------------
# 
	$template->assign_vars(array(
		.
		.
		.
		.
		'INTERESTS' => $interests,

# 
#-----[ ADD BELOW ]---------------------------------------------------
# 
		'MUSIC' => $music,
		'L_MUSIC' => $lang['Music'],

Gebruikersavatar
WebSiteNet
Berichten: 6524
Lid geworden op: 20 okt 2003, 16:56
Locatie: Wieringerwerf
Contacteer:

Bericht door WebSiteNet » 04 jan 2004, 17:36

Verander

Code: Selecteer alles

// 
// Get current date 
// 
$sql = "INSERT INTO " . USERS_TABLE . " (user_id, username, user_regdate, user_password, user_email, user_icq, user_website, user_occ, user_from, user_interests, user_music, user_sig, user_sig_bbcode_uid, user_avatar, user_avatar_type, user_viewemail, user_aim, user_yim, user_msnm, user_attachsig, user_allowsmile, user_allowhtml, user_allowbbcode, user_allow_viewonline, user_notify, user_notify_pm, user_popup_pm, user_timezone, user_dateformat, user_lang, user_style, user_level, user_allow_pm, user_active, user_actkey) 
VALUES ($user_id, '" . str_replace("\'", "''", $username) . "', " . time() . ", '" . str_replace("\'", "''", $password) . "', '" . str_replace("\'", "''", $email) . "', '" . str_replace("\'", "''", $icq) . "', '" . str_replace("\'", "''", $website) . "', '" . str_replace("\'", "''", $occupation) . "', '" . str_replace("\'", "''", $location) . "', '" . str_replace("\'", "''", $interests) . "', '" . str_replace("\'", "''", $music) . "', '" . str_replace("\'", "''", $signature) . "', '$signature_bbcode_uid', $avatar_sql, $viewemail, '" . str_replace("\'", "''", str_replace(' ', '+', $aim)) . "', '" . str_replace("\'", "''", $yim) . "', '" . str_replace("\'", "''", $msn) . "', $attachsig, $allowsmilies, $allowhtml, $allowbbcode, $allowviewonline, $notifyreply, $notifypm, $popuppm, $user_timezone, '" . str_replace("\'", "''", $user_dateformat) . "', '" . str_replace("\'", "''", $user_lang) . "', $user_style, 0, 1, '$birthday', '$next_birthday_greeting',"; 
if ( $board_config['require_activation'] == USER_ACTIVATION_SELF || $board_config['require_activation'] == USER_ACTIVATION_ADMIN || $coppa ) 
{ 
$user_actkey = gen_rand_string(true); 
$key_len = 54 - (strlen($server_url)); 
$key_len = ( $key_len > 6 ) ? $key_len : 6; 
$user_actkey = substr($user_actkey, 0, $key_len); 
$sql .= "0, '" . str_replace("\'", "''", $user_actkey) . "')"; 
} 
else 
{ 
$sql .= "1, '')"; 
} 
in

Code: Selecteer alles

// 
// Get current date 
// 
$notifyreply = ( !empty($notifyreply) ) ? $notifyreply : 0;
$sql = "INSERT INTO " . USERS_TABLE . " (user_id, username, user_regdate, user_password, user_email, user_icq, user_website, user_occ, user_from, user_interests, user_music, user_sig, user_sig_bbcode_uid, user_avatar, user_avatar_type, user_viewemail, user_aim, user_yim, user_msnm, user_attachsig, user_allowsmile, user_allowhtml, user_allowbbcode, user_allow_viewonline, user_notify, user_notify_pm, user_popup_pm, user_timezone, user_dateformat, user_lang, user_style, user_level, user_allow_pm, user_active, user_actkey) 
VALUES ($user_id, '" . str_replace("\'", "''", $username) . "', " . time() . ", '" . str_replace("\'", "''", $password) . "', '" . str_replace("\'", "''", $email) . "', '" . str_replace("\'", "''", $icq) . "', '" . str_replace("\'", "''", $website) . "', '" . str_replace("\'", "''", $occupation) . "', '" . str_replace("\'", "''", $location) . "', '" . str_replace("\'", "''", $interests) . "', '" . str_replace("\'", "''", $music) . "', '" . str_replace("\'", "''", $signature) . "', '$signature_bbcode_uid', $avatar_sql, $viewemail, '" . str_replace("\'", "''", str_replace(' ', '+', $aim)) . "', '" . str_replace("\'", "''", $yim) . "', '" . str_replace("\'", "''", $msn) . "', $attachsig, $allowsmilies, $allowhtml, $allowbbcode, $allowviewonline, $notifyreply, $notifypm, $popuppm, $user_timezone, '" . str_replace("\'", "''", $user_dateformat) . "', '" . str_replace("\'", "''", $user_lang) . "', $user_style, 0, 1, '$birthday', '$next_birthday_greeting',"; 
if ( $board_config['require_activation'] == USER_ACTIVATION_SELF || $board_config['require_activation'] == USER_ACTIVATION_ADMIN || $coppa ) 
{ 
$user_actkey = gen_rand_string(true); 
$key_len = 54 - (strlen($server_url)); 
$key_len = ( $key_len > 6 ) ? $key_len : 6; 
$user_actkey = substr($user_actkey, 0, $key_len); 
$sql .= "0, '" . str_replace("\'", "''", $user_actkey) . "')"; 
} 
else 
{ 
$sql .= "1, '')"; 
} 

Gebruikersavatar
hotrid
Berichten: 452
Lid geworden op: 24 jun 2003, 14:33
Locatie: Almelo
Contacteer:

Bericht door hotrid » 04 jan 2004, 17:41

JE krijgt nog steeds de foutmelding

Code: Selecteer alles

Could not update users table

DEBUG MODE

SQL Error : 1064 You have an error in your SQL syntax near ' user_timezone = 1, user_dateformat = 'd F Y G:i', user_lang = 'dutch', user_sty' at line 2

UPDATE phpbb_users SET user_email = 'hotrid@hotmail.com', user_icq = '', user_website = 'http://www.hotrid.nl/forum/', user_occ = 'Student enzo', user_from = 'Almelo', user_interests = 'Beheerder van www.hotrid.nl', user_music = 'Trance, Dance, Techno & Rock', user_sig = 'Forum Verpest het nietd', user_sig_bbcode_uid = '1467017975', user_viewemail = 1, user_aim = '', user_yim = '', user_msnm = 'hotrid@hotmail.com', user_attachsig = 1, user_allowsmile = 1, user_allowhtml = 1, user_allowbbcode = 1, user_allow_viewonline = 1, user_notify = 0, user_notify_pm = 0, user_popup_pm = , user_timezone = 1, user_dateformat = 'd F Y G:i', user_lang = 'dutch', user_style = 2, user_active = 1, user_actkey = '' WHERE user_id = 2

Line : 518
File : /home/virtual/site19/fst/var/www/html/forum/includes/usercp_register.php

Gesloten