mirror of
https://github.com/phpbb/phpbb.git
synced 2025-05-06 07:35:29 +02:00
Change guest username validation in line with how registered usernames are checked
git-svn-id: file:///svn/phpbb/branches/phpBB-2_0_0@3187 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
parent
aab01d335a
commit
20d5fc0aa3
@ -141,6 +141,7 @@ h3 {font-size:12pt;color:blue}
|
|||||||
<li>Fixed some problems with gzip in combination with newer PHP versions and Mozilla</li>
|
<li>Fixed some problems with gzip in combination with newer PHP versions and Mozilla</li>
|
||||||
<li>Fixed wrong maxlength in modcp_split.tpl subject field</li>
|
<li>Fixed wrong maxlength in modcp_split.tpl subject field</li>
|
||||||
<li>Fixed inability to edit username of guest poster - <b>vHiker</b></li>
|
<li>Fixed inability to edit username of guest poster - <b>vHiker</b></li>
|
||||||
|
<li>Fixed ability for guests to post with certain registered usernames</li>
|
||||||
<li></li>
|
<li></li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
|
@ -150,7 +150,7 @@ function prepare_post(&$mode, &$post_data, &$bbcode_on, &$html_on, &$smilies_on,
|
|||||||
// Check username
|
// Check username
|
||||||
if ( !empty($username) )
|
if ( !empty($username) )
|
||||||
{
|
{
|
||||||
$username = htmlspecialchars(trim(strip_tags($username)));
|
$username = trim(strip_tags($username));
|
||||||
|
|
||||||
if ( !$userdata['session_logged_in'] || ( $userdata['session_logged_in'] && $username != $userdata['username'] ) )
|
if ( !$userdata['session_logged_in'] || ( $userdata['session_logged_in'] && $username != $userdata['username'] ) )
|
||||||
{
|
{
|
||||||
@ -162,6 +162,10 @@ function prepare_post(&$mode, &$post_data, &$bbcode_on, &$html_on, &$smilies_on,
|
|||||||
$error_msg .= ( !empty($error_msg) ) ? '<br />' . $result['error_msg'] : $result['error_msg'];
|
$error_msg .= ( !empty($error_msg) ) ? '<br />' . $result['error_msg'] : $result['error_msg'];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$username = '';
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Check subject
|
// Check subject
|
||||||
|
Loading…
x
Reference in New Issue
Block a user