mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-07 20:08:53 +00:00
[ticket/14072] Add core event to the function format_display()
PHPBB3-14072
This commit is contained in:
parent
f34f28f283
commit
9e467a4e4a
1 changed files with 23 additions and 0 deletions
|
@ -1301,6 +1301,29 @@ class parse_message extends bbcode_firstpass
|
|||
$return_message = &$this->message;
|
||||
}
|
||||
|
||||
$text = $this->message;
|
||||
$uid = $this->bbcode_uid;
|
||||
|
||||
/**
|
||||
* Event to modify the text before it is parsed
|
||||
*
|
||||
* @event core.modify_format_display_text_before
|
||||
* @var string text The message text to parse
|
||||
* @var string uid The bbcode uid
|
||||
* @var bool allow_bbcode Do we allow bbcodes
|
||||
* @var bool allow_magic_url Do we allow magic urls
|
||||
* @var bool allow_smilies Do we allow smilies
|
||||
* @var bool update_this_message Do we update the internal message
|
||||
* with the parsed result
|
||||
* @since 3.1.6-RC1
|
||||
*/
|
||||
$vars = array('text', 'uid', 'allow_bbcode', 'allow_magic_url', 'allow_smilies', 'update_this_message');
|
||||
extract($phpbb_dispatcher->trigger_event('core.modify_format_display_text_before', compact($vars)));
|
||||
|
||||
$this->message = $text;
|
||||
$this->bbcode_uid = $uid;
|
||||
unset($text, $uid);
|
||||
|
||||
if ($this->message_status == 'plain')
|
||||
{
|
||||
// Force updating message - of course.
|
||||
|
|
Loading…
Add table
Reference in a new issue