How to create the custom flash messages in cakephp
1) First of all go to the -> app/View/Elements and create the ctp file for the flash_warning.ctp.
2) And add content in the ctp file like
<div>
<?php echo h($message); ?>
</div>
3) warning then call the ” $this->Session->setFlash(‘Your Profile Update Successfully’,’flash_success’); ” in cakephp controller.