Flash messages

Descripción

How to display a Flash Messages on your code.
Elvis Moraes
Apunte por Elvis Moraes, actualizado hace más de 1 año
Elvis Moraes
Creado por Elvis Moraes hace alrededor de 5 años
7
0

Resumen del Recurso

Página 1

basic:   Usage on controller $this->addFlash(             'notice',             'Your changes were saved!' );   Usage on template (html) {% for message in app.flashes('notice') %}       <div class="flash-notice">          {{ message }}       </div> {% endfor %}

Página 2

Another e.g.   Usage on controller         $this->addFlash(             'warning',             'Your changes NOT saved!'         );   Usage on template (html) {% for label, messages in app.flashes %}     {% for message in messages %}         <div class="flash-{{ label }}">             {{ message }}         </div>     {% endfor %} {% endfor %}

Mostrar resumen completo Ocultar resumen completo

Similar

Health & Safety Signs
Oliver Balay
Poetic Devices
erinpalmer
GCSE Business Key Terms
ChrisDev
GCSE Computing : OCR Computing
Samuel Wooster
MCO population
zachary.frechett
Computer Networks Flashcards
Joel Smith
Do you know Happy Wheels ?
Apotheose
Power in DC Circuits (Mod.2 Sect.2 part3)
That Yeti Dog Person
Calculating Circuit Resistance (Mod.2 sect.2 part1) 1 of 2
That Yeti Dog Person
Ohm's Law -REVIEW SECTION- (Mod.2 Sect.2 part2)
That Yeti Dog Person
Relative Conductivity of Metals at 20 Degrees Celsius
That Yeti Dog Person