[TYPO3-mvc] How to replace deprecated method FlashMessageContainer->add()
Markus Klein
klein.t3 at mfc-linz.at
Sun Jan 19 13:38:49 CET 2014
Hi Dirk,
you should use:
$this->controllerContext->getFlashMessageQueue()->enqueue()
In 6.2 you can also use $this->addFlashMessage() like in Flow
Kind regards
Markus
------------------------------------------------------------
Markus Klein
TYPO3 CMS Active Contributors Team Member
> -----Original Message-----
> From: typo3-project-typo3v4mvc-bounces at lists.typo3.org [mailto:typo3-
> project-typo3v4mvc-bounces at lists.typo3.org] On Behalf Of Dirk Wenzel
> Sent: Sunday, January 19, 2014 1:25 PM
> To: typo3-project-typo3v4mvc at lists.typo3.org
> Subject: [TYPO3-mvc] How to replace deprecated method
> FlashMessageContainer->add()
>
> The method FlashMessageContainer->add() is deprecated since TYPO3
> version 6.1.
>
> Would you use
> $this->controllerContext->getFlashMessageQueue()->addMessage(new
> \TYPO3\CMS\Core\Messaging\FlashMessage('<message text>', '<message
> header', \TYPO3\CMS\Core\Messaging\FlashMessage::<message type
> constant>)); instead?
>
> A comment in the FlashMessageQueue class states that the method
> addMessage() is not yet visible and will be made public in version 6.3.
>
> Cheers
> Dirk
>
> _______________________________________________
> TYPO3-project-typo3v4mvc mailing list
> TYPO3-project-typo3v4mvc at lists.typo3.org
> http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-project-typo3v4mvc
More information about the TYPO3-project-typo3v4mvc
mailing list