mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-28 06:08:52 +00:00
Force password change after defined number of days
git-svn-id: file:///svn/phpbb/trunk@4793 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
parent
f8b89a8f94
commit
7baa9ddb89
1 changed files with 13 additions and 0 deletions
|
@ -575,6 +575,19 @@ class user extends session
|
||||||
|
|
||||||
$this->img_lang = (file_exists($phpbb_root_path . 'styles/' . $this->theme['primary']['imageset_path'] . '/imageset/' . $this->lang_name)) ? $this->lang_name : $config['default_lang'];
|
$this->img_lang = (file_exists($phpbb_root_path . 'styles/' . $this->theme['primary']['imageset_path'] . '/imageset/' . $this->lang_name)) ? $this->lang_name : $config['default_lang'];
|
||||||
|
|
||||||
|
// Does the user need to change their password? If so, redirect to the
|
||||||
|
// ucp profile reg_details page ... of course do not redirect if we're
|
||||||
|
// already in the ucp
|
||||||
|
if (!defined('IN_ADMIN') && $config['chg_passforce'] && $this->data['user_passchg'] < time() - ($config['chg_passforce'] * 86400))
|
||||||
|
{
|
||||||
|
global $SID;
|
||||||
|
|
||||||
|
if (!preg_match('#' . preg_quote("ucp.$phpEx$SID") . '&i\=[a-z0-9]+?&mode\=reg_details#', $_SERVER['REQUEST_URI']))
|
||||||
|
{
|
||||||
|
redirect("ucp.$phpEx$SID&i=profile&mode=reg_details");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue