mirror of
https://github.com/phpbb/phpbb.git
synced 2025-08-11 11:13:59 +02:00
Merge pull request #5860 from JoshyPHP/ticket/16361
[ticket/16361] Change the link shortener
This commit is contained in:
@@ -549,8 +549,8 @@ class acp_board
|
||||
}
|
||||
}
|
||||
|
||||
// Invalidate the text_formatter cache when posting options are changed
|
||||
if ($mode == 'post' && $submit)
|
||||
// Invalidate the text_formatter cache when posting or server options are changed
|
||||
if (preg_match('(^(?:post|server)$)', $mode) && $submit)
|
||||
{
|
||||
$phpbb_container->get('text_formatter.cache')->invalidate();
|
||||
}
|
||||
|
@@ -470,11 +470,17 @@ class factory implements \phpbb\textformatter\cache_interface
|
||||
$tag->attributes->add('text');
|
||||
$tag->template = '<xsl:value-of select="@text"/>';
|
||||
|
||||
$board_url = generate_board_url() . '/';
|
||||
$tag->filterChain
|
||||
->add(array($this->link_helper, 'truncate_local_url'))
|
||||
->resetParameters()
|
||||
->addParameterByName('tag')
|
||||
->addParameterByValue(generate_board_url() . '/');
|
||||
->addParameterByValue($board_url);
|
||||
$tag->filterChain
|
||||
->add(array($this->link_helper, 'truncate_local_url'))
|
||||
->resetParameters()
|
||||
->addParameterByName('tag')
|
||||
->addParameterByValue(preg_replace('(^\\w+:)', '', $board_url));
|
||||
$tag->filterChain
|
||||
->add(array($this->link_helper, 'truncate_text'))
|
||||
->resetParameters()
|
||||
|
Reference in New Issue
Block a user