Solved thread

This post is marked as solved. If you think the information contained on this thread must be part of the official documentation, please contribute submitting a pull request to its repository.

Vokuro Model Email Notice

In vokuro, on registering a user, a mail is sent from the model's aftersave() method which has the following code.

$this->getDI()->getFlash()->notice('A confirmation mail has been sent to ' . $this->email);

This does not obey the template and shows this message in a blank page.

I want this notification in my controller where the $user->save() is called, and from there i want to show the message as done in the model.

Any help will be appreciated.



9.1k
Accepted
answer

Hi @assadnazar the flash services show messages in the same request and you can print it using echo content() in you view. If you use flashSession service, messages are stored in session until you print it using echo flashSession->output().

More info flash services

Good luck