projects
/
platal.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Port to PlWikiPage structure.
[platal.git]
/
modules
/
register.php
diff --git
a/modules/register.php
b/modules/register.php
index
7fea993
..
6f351c6
100644
(file)
--- a/
modules/register.php
+++ b/
modules/register.php
@@
-83,8
+83,8
@@
class RegisterModule extends PLModule
switch ($sub_state['step']) {
case 0:
switch ($sub_state['step']) {
case 0:
-
require_once('wiki.inc.php
');
-
wiki_require_page('Reference.Charte'
);
+
$wp = new PlWikiPage('Reference.Charte
');
+
$wp->buildCache(
);
if (Post::has('step1')) {
$sub_state['step'] = 1;
if (isset($sub_state['hash'])) {
if (Post::has('step1')) {
$sub_state['step'] = 1;
if (isset($sub_state['hash'])) {
@@
-175,7
+175,7
@@
class RegisterModule extends PLModule
}
}
if ($sub_state['watch']) {
}
}
if ($sub_state['watch']) {
- $al
ter
.= "Inscription d'un utilisateur surveillé - ";
+ $al
ert
.= "Inscription d'un utilisateur surveillé - ";
}
if (check_ip('unsafe')) {
}
if (check_ip('unsafe')) {
@@
-214,12
+214,12
@@
class RegisterModule extends PLModule
}
$_SESSION['sub_state'] = $sub_state;
}
$_SESSION['sub_state'] = $sub_state;
- if (
$alert
) {
+ if (
!empty($alert)
) {
send_warning_mail($alert);
}
$page->changeTpl('register/step'.intval($sub_state['step']).'.tpl');
if (isset($err)) {
send_warning_mail($alert);
}
$page->changeTpl('register/step'.intval($sub_state['step']).'.tpl');
if (isset($err)) {
- $page->trig($err);
+ $page->trig
Error
($err);
}
}
}
}
@@
-300,8
+300,8
@@
class RegisterModule extends PLModule
$redirect->add_email($email);
// on cree un objet logger et on log l'inscription
$redirect->add_email($email);
// on cree un objet logger et on log l'inscription
- $logger = new
Core
Logger($uid);
-
$logger
->log('inscription', $email);
+ $logger = new
Pl
Logger($uid);
+
S::logger()
->log('inscription', $email);
XDB::execute('UPDATE register_pending SET hash="INSCRIT" WHERE uid={?}', $uid);
XDB::execute('UPDATE register_pending SET hash="INSCRIT" WHERE uid={?}', $uid);
@@
-317,7
+317,7
@@
class RegisterModule extends PLModule
user_reindex($uid);
// update number of subscribers (perms has changed)
user_reindex($uid);
// update number of subscribers (perms has changed)
-
update_
NbIns();
+
$globals->update
NbIns();
if (!start_connexion($uid, false)) {
return PL_FORBIDDEN;
if (!start_connexion($uid, false)) {
return PL_FORBIDDEN;
@@
-416,7
+416,7
@@
class RegisterModule extends PLModule
}
$log = S::v('log');
}
$log = S::v('log');
-
$log
->log('passwd', '');
+
S::logger()
->log('passwd', '');
if (Cookie::v('ORGaccess')) {
require_once('secure_hash.inc.php');
if (Cookie::v('ORGaccess')) {
require_once('secure_hash.inc.php');