PHP code example of dotkernel / dot-flashmessenger
1. Go to this page and download the library: Download dotkernel/dot-flashmessenger library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
$this->flashMessenger->addMessage('error', 'This is a error flash message');
//on the next request you can get all messages from a namespace, or all messages from all namespaces if the namespace is omitted
$this->flashMessenger->getMessages('error');
$this->flashMessenger->addData('myData', $someData);
// next request
$this->flashMessenger->getData('myData');
public function addError(string|array $error);
public function addInfo(string|array $info);
public function addWarning(string|array $warning);
public function addSuccess(string|array $success);
Dot\FlashMessenger\FlashMessengerInterface::class
Dot\FlashMessenger\View\RendererInterface::class
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.