oc |
|
---|---|
So, the idea is, let everybody change their emails, but prevent security flaws by making reactivation on email change mandatory.
Process is, if user is able to change his/her email (still with the option from administration/users) and if he changes his email, an activation email is being send, and this way email's validity is checked, and one mail/one user policy is remain safe. Already coded and imported the language stuff, but because of the "no enhancement after Jan 25" it is N-0.1.0 feature. (If not liked, sure will be cancelled) What do you think ? ~edit: so, code in, users.profile.inc.php, right after the code:
$ruserbirthdate = ($rmonth==0 || $rday ==0 || $ryear==0) ? 0 : sed_mktime(1, 0, 0, $rmonth, $rday, $ryear);
if (!$cfg['useremailchange'])
{ $ruseremail = $urr['user_email']; }
Same on that file, change the whole $profile_form_email with:
$profile_form_email = ($cfg['useremailchange']) ? "<input type=\"text\" class=\"text\" name=\"ruseremail\" value=\"".sed_cc($urr['user_email'])."\" size=\"32\" maxlength=\"64\" />" : "<input type=\"text\" class=\"text\" name=\"ruseremail\" value=\"".sed_cc($urr['user_email'])."\" size=\"32\" maxlength=\"64\" disabled=\"disabled\" />";
And in users.register.inc.php, change whole 'validate' part with: http://www.cotonti.com/pastebin/9 And of course, last, add after {USERS_PROFILE_EMAIL}: <div style="font-size: xx-small;">{PHP.skinlang.usersprofile.Emailnotes}</div> Not the perfect usage of new Pastebin but I wanted you to see code and bug fix it, and to keep the code here safely. |
|
Відредаговано: oc (31.01.2009 07:56, 16 років тому) |