summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2000-10-25 11:23:29 +0000
committerDries Buytaert <dries@buytaert.net>2000-10-25 11:23:29 +0000
commit4ede9967c1938429d1470f308c37e48a0a2efa3b (patch)
tree68c728cc6171eb2a0427a9a39fdc67a658549418
parente282fef076567cbacb56e7053c5093aba1b36880 (diff)
downloadbrdo-4ede9967c1938429d1470f308c37e48a0a2efa3b.tar.gz
brdo-4ede9967c1938429d1470f308c37e48a0a2efa3b.tar.bz2
* fixed the login problem
-rw-r--r--account.php9
1 files changed, 5 insertions, 4 deletions
diff --git a/account.php b/account.php
index de9ba64d8..f349ff226 100644
--- a/account.php
+++ b/account.php
@@ -24,7 +24,6 @@ function account_session_start($userid, $passwd) {
global $user;
$user = new User($userid, $passwd);
-
if ($user->id) {
session_start();
session_register("user");
@@ -170,7 +169,7 @@ function account_page_save($edit) {
function account_user($uname) {
global $user, $theme;
-
+
if ($user->id && $user->userid == $uname) {
$output .= "<P>Welcome $user->userid! This is <B>your</B> user info page. There are many more, but this one is yours. You are probably most interested in editing something, but if you need to kill some time, this place is as good as any other place.</P>\n";
$output .= "<TABLE BORDER=\"0\" CELLPADDING=\"2\" CELLSPACING=\"2\">\n";
@@ -275,7 +274,9 @@ function account_register_enter($user = "", $error = "") {
}
function account_register_submit($new) {
- global $theme, $mail, $sitename;
+ global $theme, $mail, $sitename, $siteurl;
+
+ $siteurl = "www.drop.org"; // temporary solution
if ($rval = account_validate($new)) {
account_register_enter($new, "$rval");
@@ -287,7 +288,7 @@ function account_register_submit($new) {
user_save($new);
- $link = "http://". getenv("HOSTNAME") ."/account.php?op=confirm&name=$new[userid]&hash=$new[hash]";
+ $link = "http://$siteurl/account.php?op=confirm&name=$new[userid]&hash=$new[hash]";
$message = "$new[userid],\n\n\nsomeone signed up for a user account on $sitename and supplied this email address as their contact. If it wasn't you, don't get your panties in a knot and simply ignore this mail.\n\nIf this was you, you have to activate your account first before you can login. You can do so simply by visiting the URL below:\n\n $link\n\nVisiting this URL will automatically activate your account. Once activated you can login using the following information:\n\n username: $new[userid]\n password: $new[passwd]\n\n\n-- $sitename crew\n";
mail($new[real_email], "Account details for $sitename", $message, "From: noreply@$sitename");