1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-08-09 02:06:32 +02:00

Merge branch 'develop-olympus' into develop

* develop-olympus:
  [ticket/9851] "Search new posts" should require login.
  [task/phpdoc] Added a phpdoc task to the build process
  [task/phpdoc] Added a configuration file for phpDocumentor.
  [feature/acm-wincache] Adding caching module for WinCache's User Cache.
  [ticket/9939] Fix JavaScript error in admin recaptcha template
  [ticket/9575] Also change 'administrate' to 'administer' in templates
  [ticket/8736] guest can have 255 chars long username
  [ticket/9928] Do not link "login to your board" to the "send statistics" page.
  [ticket/9575] Change 'administrate' to 'administer'
  [ticket/9921] Adding sample configuration file for the lighttpd webserver.
  [ticket/9932] Add the Bing bot when converting
  [ticket/9930] Redirect failes with open_basedir enabled.
  [ticket/9910] Make sure S_BBCODE_ALLOWED exists when viewing PMs
This commit is contained in:
Nils Adermann
2010-12-13 17:14:36 +01:00
17 changed files with 313 additions and 33 deletions

View File

@@ -861,11 +861,18 @@ if ($submit || $preview || $refresh)
{
include($phpbb_root_path . 'includes/functions_user.' . $phpEx);
$user->add_lang('ucp');
if (($result = validate_username($post_data['username'], (!empty($post_data['post_username'])) ? $post_data['post_username'] : '')) !== false)
{
$user->add_lang('ucp');
$error[] = $user->lang[$result . '_USERNAME'];
}
if (($result = validate_string($post_data['username'], false, $config['min_name_chars'], $config['max_name_chars'])) !== false)
{
$min_max_amount = ($result == 'TOO_SHORT') ? $config['min_name_chars'] : $config['max_name_chars'];
$error[] = sprintf($user->lang['FIELD_' . $result], $user->lang['USERNAME'], $min_max_amount);
}
}
if ($config['enable_post_confirm'] && !$user->data['is_registered'] && in_array($mode, array('quote', 'post', 'reply')))