Seite 2 von 2

Verfasst: 09.06.2006 15:39
von h-o
Da ist einiges nicht ganz richtig.

Folgendes mal bitte bei Gelegenheit machen:

Code: Alles auswählen

FINDE

$signature = (isset($signature)) ? str_replace('<br />', "\n", $signature) : '';
$signature_bbcode_uid = '';

DARUNTER EINFÜGEN

$gender = ( isset($HTTP_POST_VARS['gender']) ) ? intval ($HTTP_POST_VARS['gender']) : 0;


FINDE

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_birthday = '$birthday', user_next_birthday_greeting = '$next_birthday_greeting', 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 = $popup_pm, 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 . ", user_gender = '$gender', user_gender = '$gender', user_gender = '$gender'
WHERE user_id = $user_id";

ERSETZTE MIT

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_birthday = '$birthday', user_next_birthday_greeting = '$next_birthday_greeting', 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 = $popup_pm, 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 . ", user_gender = '$gender'
WHERE user_id = $user_id";


FINDE

$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_allow_pm, user_level, user_gender, user_birthday, user_next_birthday_greeting, user_active, user_actkey) VALUES ($user_id, '" . str_replace("\'", "''", $username) . "', " . time() . ", '" . str_replace("\'", "''", $new_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, $popup_pm, $user_timezone, '" . str_replace("\'", "''", $user_dateformat) . "', '" . str_replace("\'", "''", $user_lang) . "', $user_style, '$gender', '$gender', '$gender', 0, 1, '$birthday', '$next_birthday_greeting', ";

ERSETZTE MIT

$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_gender, user_level, user_allow_pm, user_birthday, user_next_birthday_greeting, user_active, user_actkey)
VALUES ($user_id, '" . str_replace("\'", "''", $username) . "', " . time() . ", '" . str_replace("\'", "''", $new_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, $popup_pm, $user_timezone, '" . str_replace("\'", "''", $user_dateformat) . "', '" . str_replace("\'", "''", $user_lang) . "', $user_style, '$gender', 0, 1, '$birthday', '$next_birthday_greeting', ";


FINDE

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, $popup_pm, $notifyreply, $attachsig, $allowhtml, $allowbbcode, $allowsmilies, $allowviewonline, $user_style, $user_lang, $user_timezone, $user_dateformat, $userdata['session_id'], $gender, $birthday, $gender, $gender);

ERSETZTE MIT

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, $popup_pm, $notifyreply, $attachsig, $allowhtml, $allowbbcode, $allowsmilies, $allowviewonline, $user_style, $user_lang, $user_timezone, $user_dateformat, $userdata['session_id'], $gender, $birthday);
In usercp_avatar.php musst du schauen, ob in der Funktion

Code: Alles auswählen

function display_avatar_gallery($mode, &$category, &$user_id, ...
ganz hinten die Reihenfolge der Parameter dem Aufruf in der usercp_register.php entspricht, also

Code: Alles auswählen

... &$gender, &$birthday)
Vorher sicherheitshalber ein Backup von usercp_register.php machen :-)

Verfasst: 09.06.2006 18:13
von FCM
:cry:

Schade ich hab den Gender weggegeben. :cry: Denkst du, dassd u ihn mir installieren kannst?

Verfasst: 15.07.2006 02:27
von tihass
Hallo,

Ich habe das gleich Problem ! In dem Profile wird die Einstellung für das Geschlecht nicht übernommen. Ich habe den Gender_1.2.8em und nutze das PHPBB 2.0.19 und nach Installationsanweisung in der usercp_register.php die so begint:

#
#-----[ FIND ]------------------------------------------------
#
$signature_bbcode_uid = '';

#
#-----[ AFTER, ADD ]------------------------------------------
#

// Start add - Gender MOD
$gender = ( isset($HTTP_POST_VARS['gender']) ) ? intval ($HTTP_POST_VARS['gender']) : 0;
// End add - Gender MOD

Habe ich das Problem das ich diese Zeile nicht finde: $signature_bbcode_uid = '';

Meine usercp_register.php scheint eine andere Strukture zu haben !

Hier ein Link zur unbearbeiteten Date: http://dateihoster.de/preview.php?file= ... a7ff26.rar

Bitte,bitte kann mir jemand helfen ?

Wer sehr schade wen ich diesen Mod wieder rausschmeißen müßte !

Für Hilfe bedanke ich mich recht herzlich ! :grin:

Gruß

Aspirin

Verfasst: 18.07.2006 15:59
von h-o
tihass hat geschrieben:Ich habe den Gender_1.2.8em und nutze das PHPBB 2.0.19
[...]
Habe ich das Problem das ich diese Zeile nicht finde: $signature_bbcode_uid = '';

Meine usercp_register.php scheint eine andere Strukture zu haben!
Klug erkannt! :-)

Suche in usercp_register.php mal nach

Code: Alles auswählen

$signature = str_replace(
Besser wäre es übrigens, das Forum wegen einiger Sicherheitslücken in der veralteten Version auf den neuesten Stand zu bringen, sonst brauchst du möglicherweise bald sehr viele...
Aspirin
Genau! :D

Verfasst: 19.07.2006 16:17
von tihass
Hallo,

Vielen Dank für die Hilfe, hatt geklappt !

Muß mal schauen wie ich das ganze auf 2.0.21 update ? Ich werde mal mit Patch versuchen. Ich habe einige Mods eingebaut, bei dem Gedanken ganz von vorne zu beginnen wird mir schlecht ! Oder ich muß es von Hand updaten, ist wohl auch ein mühseliger weg ! Oder hast du noch eine gute Idee ?

Gruß