Search code examples
cakephp-3.0cakephp-3.xcakephp-3.4cakephp-bootstrap-ui

How to use own element file for flash instead of Bootstrap-ui's default, CakePHP 3?


I am using bootstrap-ui plugin for Form but it automatically loads flash. I want to use my own element file for Success/Error/Warning etc but bootstrap-ui automatically uses its default.ctp element for rending flash message.

So how can I use my own element files for displaying the flash message?


Solution

  • You can overwrite the flash template on app level, like any other plugin template:

    src/Template/Plugin/BootstrapUI/Element/Flash/default.ctp
    

    See also