• R/O
  • HTTP
  • SSH
  • HTTPS

nucleus-plugins: Commit

Nucleus CMS日本語版用プラグインのうち、日本語版開発者がサポートしているもの


Commit MetaInfo

Revision1d90f68bfb879f0c53b74eaae3aad6912c1256f7 (tree)
Time2009-07-01 17:34:13
Authorshizuki <shizuki@1ca2...>
Commitershizuki

Log Message

管理画面からの新規登録とログインは確認済み

git-svn-id: https://svn.sourceforge.jp/svnroot/nucleus-jp/plugin@1024 1ca29b6e-896d-4ea0-84a5-967f57386b96

Change Summary

Incremental Difference

--- a/NP_MailaddressLogin/trunk/NP_MailaddressLogin.php
+++ b/NP_MailaddressLogin/trunk/NP_MailaddressLogin.php
@@ -2,7 +2,6 @@
22
33 class NP_MailaddressLogin extends NucleusPlugin
44 {
5-{
65 function getName()
76 {
87 return 'Login by Mailaddress';
@@ -53,10 +52,10 @@ class NP_MailaddressLogin extends NucleusPlugin
5352 SELECT
5453 mname as result
5554 FROM
56- ' . sql_query('member') . '
55+ ' . sql_table('member') . '
5756 WHERE
58- memail = ' . sql_real_escape_string($data['login']) ' and
59- mpassword = ' . md5($data['password']);
57+ memail = "' . sql_real_escape_string($data['login']) . '" and
58+ mpassword = "' . md5($data['password']) . '"';
6059 if ($mname = quickQuery($query)) {
6160 $data['login'] = $mname;
6261 $data['success'] = 1;
@@ -75,19 +74,13 @@ class NP_MailaddressLogin extends NucleusPlugin
7574 SELECT
7675 COUNT(*) as result
7776 FROM
78- ' . sql_query('member') . '
77+ ' . sql_table('member') . '
7978 WHERE
80- memail = ' $mailAddr
79+ memail = "' . sql_real_escape_string($mailAddr) . '"'
8180 );
82- if ($userMail > 0) {
83- $query = '
84- DELETE
85- FROM
86- ' . sql_query('member') . '
87- WHERE
88- mnumber = ' . $this->getID();
89- sql_query($query);
90- $data['member'] = false;
81+ if ($userMail > 1) {
82+ $adm = new ADMIN;
83+ $adm->deleteOneMember($member->getID());
9184 return;
9285 }
9386 }
@@ -108,11 +101,10 @@ class NP_MailaddressLogin extends NucleusPlugin
108101 SELECT
109102 COUNT(*) as result
110103 FROM
111- ' . sql_query('member') .
104+ ' . sql_table('member') .
112105 '
113106 WHERE
114- memail = ' $mailAddr
115- '
107+ memail = "' . sql_real_escape_string($mailAddr) . '"'
116108 );
117109 if ($userMail > 0) {
118110 $data['error'] = 'Mail address is avaiable';
Show on old repository browser