[TYPO3-core] RFC #11684: Add support for flash messages in the backend

Michael Stucki michael at typo3.org
Tue Aug 25 01:43:09 CEST 2009


Hi Ingo,

+1 on testing changed_warningboxes.diff. Another +1 was already given by
Francois.

Additionally, there are two positive feedbacks based on code review, but
I would also like to have a look at this, though not right now.

So all in all, the patch is ready for commit now. However, as I wrote to
Xavier already, there is some missing stuff that should be implemented
if the overall goal is to provide this as a standard API (which is the
the case definitely!) I'm asking you to take care of this or, if not
possible for some reason, find someone else who implements this stuff.

Regards, and thanks for your work on that!

- michael

Ingo Renner schrieb:
> Hi *,
> 
> This is an SVN patch request.
> 
> Type: feature
> 
> Bugtracker references:
> http://bugs.typo3.org/view.php?id=11684
> 
> Branches: trunk
> 
> Problem:
> Currently there's no nice way to show notices, information, success,
> warning, or error messages to the user.
> 
> Solution:
> In the ruby on rails world they have a thing they call flash messages.
> Introducing these to the TYPO3 backend also gives us a nice way to show
> mentioned messages.
> They're called "flash" message as they only live for the duration of a
> request. Furthermore they can be improved in a second step to disapear
> automatically after some time or can carry a small "close" link.
> 
> The icons need to be placed in typo3/gfx/. The notice message
> intentionally doesn't have an icon as it's got very low severity.
> 
> There're one thing I'd like to get comments on:
>  * Currently neither title nor message are htmlspecialchars()ed to allow
> a message to carry links or have lists like in the demo extension.
> Should/can this stay like it is or should an optional parameter for both
> set() methods be introduced to en/disable escaping (defaulting to escape
> = true)
> 
> 
> Notes:
> Some of the code - the way how messages get added to the document (class
> template) - is taken from FLOW3. FLOW3 however, does not have a
> dedicated class to represent a flash message.
> 
> To test the messages you can use the attached test extension.
> 
> Usage example (backend module context):
> 
> $flashMessage = t3lib_div::makeInstance(
>     't3lib_FlashMessage',
>     $message, $title, $severity
> );
> $this->doc->pushFlashMessage($flashMessage);
> 
> The only thing required is the message, title is optional as well as the
> severity (defaults to OK)
> 
> 
> all the best
> Ingo
> 


-- 
Use a newsreader! Check out
http://typo3.org/community/mailing-lists/use-a-news-reader/


More information about the TYPO3-team-core mailing list