default:
case REGISTER_CLOSED:
if((! x($_SESSION,'authenticated') && (! x($_SESSION,'administrator')))) {
- $_SESSION['sysmsg'] .= "Permission denied." . EOL;
+ notice( "Permission denied." . EOL );
return;
}
- $blocked = 0;
+ $blocked = 1;
$verified = 0;
break;
}
$email =notags(trim($_POST['email']));
if((! x($username)) || (! x($email))) {
- $_SESSION['sysmsg'] .= "Please enter the required information.". EOL;
+ notice( "Please enter the required information.". EOL );
return;
}
dbesc($email)
);
if($r !== false && count($r))
- $err .= " This email address is already registered." . EOL;
+ $err .= " This email address is already registered.";
if(strlen($err)) {
- $_SESSION['sysmsg'] .= $err;
+ notice( $err . EOL );
return;
}
$newuid = intval($r[0]['uid']);
}
else {
- $_SESSION['sysmsg'] .= "An error occurred during registration. Please try again." . EOL;
+ notice( "An error occurred during registration. Please try again." . EOL );
return;
}
);
if($r === false) {
- $_SESSION['sysmsg'] .= "An error occurred creating your default profile. Please try again." . EOL ;
+ notice( "An error occurred creating your default profile. Please try again." . EOL );
// Start fresh next time.
$r = q("DELETE FROM `user` WHERE `uid` = %d",
intval($newuid));
}
if($res) {
- $_SESSION['sysmsg'] .= "Registration successful. Please check your email for further instructions." . EOL ;
+ notice( "Registration successful. Please check your email for further instructions." . EOL ) ;
goaway($a->get_baseurl());
}
else {
- $_SESSION['sysmsg'] .= "Failed to send email message. Here is the message that failed. $email_tpl " . EOL;
+ notice( "Failed to send email message. Here is the message that failed. $email_tpl " . EOL );
}
return;