red/green messagebox on the top

Hello,

I just want to use the red/green messagebox on the top. For validating a form and other messages. How can I use it? 

Thank you very much!