Download the PHP package atk4/outbox without Composer
On this page you can find all versions of the php package atk4/outbox. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package outbox
ATK4 Outbox
Most web applications will need to communicate with the user. Following the task-centric approach, this add-on for ATK implements various components to help communicate with the user.
The basic idea is to avoid errors and provide only one way to use the component.
How to install
composer require atk4/outbox
How to use with Atk4/Ui
Add the lines below after calling $app->initLayout()
After that you can call from any view $this->getApp()->getOutbox()
How to use without Atk4/Ui
Add the code below :
Due to missing App, init is not called so you have to do it you have to run it
Mailer (PHMailer)
- Sendmail
- Gmail
- can be customized using Atk4 direct injection :
- username
- password
- can be customized using Atk4 direct injection :
- Smtp
- can be customized using Atk4 direct injection :
- debug = PHPMailer::DEBUG_OFF;
- auth = false
- host = 'localhost';
- port = 587;
- secure = PHPMailer::ENCRYPTION_*
- username
- password
- can be customized using Atk4 direct injection :
Extend Mailer
Whatever your needs are you must respect only the contract provided by the MailerInterface
interface.
So, any Traditional SMTP or API SMTP can be added only by create a new class and define
the method : send(Mail $mail): MailResponse
, add to Outbox during initialization and use it.
If you create a new Mailer, feel free to open a PR.
How to use it
TODO
- Store the token present in a template, inside a field (at the moment, there is only a draft)
- Add more helpers to the Mail template or create a controller to manipulate it and leave it simpler as a descriptor
- Add a wysiwyg editor to edit individual templates (UI)
- Add resend system for failed messages
- Send SMS
- If you have more ideas, feel free to open an issue