mirror of
https://github.com/phpbb/phpbb.git
synced 2025-08-13 12:14:06 +02:00
Merge remote-tracking branch 'phpbb/develop' into ticket/9657
* phpbb/develop: (216 commits) [ticket/11626] Remove last reference to template in ldap [ticket/11626] Remove LDAP dependency on template [develop-olympus] Increment version number to 3.0.13-dev. [develop-olympus] Add changelog for 3.0.12 release. [develop-olympus] Bump version numbers for 3.0.12-RC1 release. [develop-olympus] Bumping version numbers to final for 3.0.12 releases. [ticket/11669] Fix PHP bug #55124 (recursive mkdir on /./) [ticket/11668] Run lint test at the end of the test suite [ticket/11548] Fix test errors in groups test on develop [ticket/11548] Check upload avatar URL the same way as in phpBB 3.0 [ticket/11548] Fix incorrect usage of array_map on acp groups page [ticket/11665] Fix test class name [ticket/11664] Stop creating php.html file in root path in tests [ticket/11665] Can't change file names already sent to set_filenames [ticket/11662] Typos: occured -> occurred [ticket/11662] Typos: occured -> occurred [ticket/11660] Fix bugs from bugs in #11651 (missing vars, db->sql_connect) [feature/auth-refactor] Add parent::setUp() in setUp() [feature/auth-refactor] Changes [feature/auth-refactor] DataProvider for acp_board test ...
This commit is contained in:
@@ -112,8 +112,8 @@ class acp_bbcodes
|
||||
{
|
||||
$template->assign_block_vars('token', array(
|
||||
'TOKEN' => '{' . $token . '}',
|
||||
'EXPLAIN' => $token_explain)
|
||||
);
|
||||
'EXPLAIN' => ($token === 'LOCAL_URL') ? sprintf($token_explain, generate_board_url() . '/') : $token_explain,
|
||||
));
|
||||
}
|
||||
|
||||
return;
|
||||
@@ -347,6 +347,9 @@ class acp_bbcodes
|
||||
'LOCAL_URL' => array(
|
||||
'!(' . str_replace(array('!', '\#'), array('\!', '#'), get_preg_expression('relative_url')) . ')!e' => "\$this->bbcode_specialchars('$1')"
|
||||
),
|
||||
'RELATIVE_URL' => array(
|
||||
'!(' . str_replace(array('!', '\#'), array('\!', '#'), get_preg_expression('relative_url')) . ')!e' => "\$this->bbcode_specialchars('$1')"
|
||||
),
|
||||
'EMAIL' => array(
|
||||
'!(' . get_preg_expression('email') . ')!ie' => "\$this->bbcode_specialchars('$1')"
|
||||
),
|
||||
@@ -373,6 +376,7 @@ class acp_bbcodes
|
||||
$sp_tokens = array(
|
||||
'URL' => '(?i)((?:' . str_replace(array('!', '\#'), array('\!', '#'), get_preg_expression('url')) . ')|(?:' . str_replace(array('!', '\#'), array('\!', '#'), get_preg_expression('www_url')) . '))(?-i)',
|
||||
'LOCAL_URL' => '(?i)(' . str_replace(array('!', '\#'), array('\!', '#'), get_preg_expression('relative_url')) . ')(?-i)',
|
||||
'RELATIVE_URL' => '(?i)(' . str_replace(array('!', '\#'), array('\!', '#'), get_preg_expression('relative_url')) . ')(?-i)',
|
||||
'EMAIL' => '(' . get_preg_expression('email') . ')',
|
||||
'TEXT' => '(.*?)',
|
||||
'SIMPLETEXT' => '([a-zA-Z0-9-+.,_ ]+)',
|
||||
@@ -429,7 +433,11 @@ class acp_bbcodes
|
||||
$fp_replace = str_replace($token, $replace, $fp_replace);
|
||||
|
||||
$sp_match = str_replace(preg_quote($token, '!'), $sp_tokens[$token_type], $sp_match);
|
||||
$sp_replace = str_replace($token, '${' . ($n + 1) . '}', $sp_replace);
|
||||
|
||||
// Prepend the board url to local relative links
|
||||
$replace_prepend = ($token_type === 'LOCAL_URL') ? generate_board_url() . '/' : '';
|
||||
|
||||
$sp_replace = str_replace($token, $replace_prepend . '${' . ($n + 1) . '}', $sp_replace);
|
||||
}
|
||||
|
||||
$fp_match = '!' . $fp_match . '!' . $modifiers;
|
||||
|
@@ -528,10 +528,10 @@ class acp_board
|
||||
$old_auth_config = array();
|
||||
foreach ($auth_providers as $provider)
|
||||
{
|
||||
if ($fields = $provider->acp($this->new_config))
|
||||
if ($fields = $provider->acp())
|
||||
{
|
||||
// Check if we need to create config fields for this plugin and save config when submit was pressed
|
||||
foreach ($fields['config'] as $field)
|
||||
foreach ($fields as $field)
|
||||
{
|
||||
if (!isset($config[$field]))
|
||||
{
|
||||
@@ -655,15 +655,14 @@ class acp_board
|
||||
|
||||
foreach ($auth_providers as $provider)
|
||||
{
|
||||
$fields = $provider->acp($this->new_config);
|
||||
|
||||
if ($fields['tpl'])
|
||||
$auth_tpl = $provider->get_acp_template($this->new_config);
|
||||
if ($auth_tpl)
|
||||
{
|
||||
$template->assign_vars($auth_tpl['TEMPLATE_VARS']);
|
||||
$template->assign_block_vars('auth_tpl', array(
|
||||
'TPL' => $fields['tpl'],
|
||||
'TEMPLATE_FILE' => $auth_tpl['TEMPLATE_FILE'],
|
||||
));
|
||||
}
|
||||
unset($fields);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -678,8 +677,12 @@ class acp_board
|
||||
$auth_plugins = array();
|
||||
$auth_providers = $phpbb_container->get('auth.provider_collection');
|
||||
|
||||
foreach($auth_providers as $key => $value)
|
||||
foreach ($auth_providers as $key => $value)
|
||||
{
|
||||
if (!($value instanceof phpbb_auth_provider_interface))
|
||||
{
|
||||
continue;
|
||||
}
|
||||
$auth_plugins[] = str_replace('auth.provider.', '', $key);
|
||||
}
|
||||
|
||||
|
@@ -410,7 +410,7 @@ class acp_groups
|
||||
if ($validation_error = validate_data($submit_ary, $validation_checks))
|
||||
{
|
||||
// Replace "error" string with its real, localised form
|
||||
$error = array_merge($error, array_map(array(&$user, 'lang'), $validation_error));
|
||||
$error = array_merge($error, $validation_error);
|
||||
}
|
||||
|
||||
if (!sizeof($error))
|
||||
@@ -507,6 +507,7 @@ class acp_groups
|
||||
|
||||
if (sizeof($error))
|
||||
{
|
||||
$error = array_map(array(&$user, 'lang'), $error);
|
||||
$group_rank = $submit_ary['rank'];
|
||||
|
||||
$group_desc_data = array(
|
||||
|
Reference in New Issue
Block a user