From c90fdf75a26e6abf2434068d4aa3cfcb190eb600 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Philip=20H=C3=A4usler?= Date: Thu, 2 Jun 2011 01:02:15 +0200 Subject: [PATCH] rewrite --- includes/pages/guest_login.php | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/includes/pages/guest_login.php b/includes/pages/guest_login.php index 76a473df..7fe081fc 100644 --- a/includes/pages/guest_login.php +++ b/includes/pages/guest_login.php @@ -34,7 +34,7 @@ function guest_register() { "`ICQ`, " . "`jabber`, " . "`Size`, " . "`Passwort`, " . "`Art` , " . "`kommentar`, " . - "`Hometown`," . "`CreateDate` ) " . + "`Hometown`," . "`CreateDate`, `Sprache` ) " . "VALUES ( " . "'" . $_POST["Nick"] . "', " . "'" . $_POST["Name"] . "', " . "'" . $_POST["Vorname"] . "', " . "'" . $_POST["Alter"] . "', " . @@ -43,7 +43,7 @@ function guest_register() { "'" . $_POST["ICQ"] . "', " . "'" . $_POST["jabber"] . "', " . "'" . $_POST["Size"] . "', " . "'" . $_POST["Passwort"] . "', " . "'" . $_POST["Art"] . "', " . "'" . $_POST["kommentar"] . "', " . - "'" . $_POST["Hometown"] . "'," . "NOW())"); + "'" . $_POST["Hometown"] . "'," . "NOW(), '" . $_SESSION['Sprache'] . "')"); if ($Erg != 1) { $html .= Get_Text("makeuser_error_write1") . "
\n"; @@ -51,16 +51,11 @@ function guest_register() { } else { $html .= "

" . Get_Text("makeuser_writeOK") . "\n"; - $SQL2 = "SELECT `UID` FROM `User` WHERE `Nick`='" . $_POST["Nick"] . "';"; - $Erg2 = mysql_query($SQL2, $con); - $Data = mysql_fetch_array($Erg2); - - $SQL3 = "INSERT INTO `UserCVS` (`UID`) VALUES ('" . $Data["UID"] . "');"; - $Erg3 = mysql_query($SQL3, $con); + $Erg3 = mysql_query("INSERT INTO `UserGroups` SET `uid`=" . sql_escape(sql_id()) . ", `group_id`=-2"); if ($Erg3 != 1) { $html .= "

" . Get_Text("makeuser_error_write2") . "
\n"; - $error = mysql_error($con); + $error = sql_error(); } else { $html .= Get_Text("makeuser_writeOK2") . "
\n"; $html .= "

" . Get_Text("makeuser_writeOK3") . "

\n";