Download the PHP package label84/laravel-mailviewer without Composer
On this page you can find all versions of the php package label84/laravel-mailviewer. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download label84/laravel-mailviewer
More information about label84/laravel-mailviewer
Files in label84/laravel-mailviewer
Package laravel-mailviewer
Short Description View mails sent by Laravel in the browser
License MIT
Informations about the package laravel-mailviewer
Laravel MailViewer
Mailviewer enables you to view and filter mail that is sent by your Laravel application in the browser. The Analytics page gives you insight in the amount of mails sent sent by your application grouped by Notification.
- Laravel Support
- Installation
- Usage
- Filters
- Analytics
- Examples
- Exclusion list
- Tests
- License
Laravel Support
Version | Release |
---|---|
11.x | ^3.0 |
10.x | ^3.0 |
Limitations
This package tracks mails sent via Laravel's Mailables
and Notifications
.
Installation
1. Require package
2. Publish the config file and migration
2.1 Publish the views (optional)
To change the default views, you can publish them to your application.
3. Run migrations
Run the migration command.
Usage
To preview the mails sent by your application visit: /admin/mailviewer
. You can change this url in the config file.
You can add MAILVIEWER_ENABLED=true
to your .env
file.
Filters
You can filter the mails in the overview with query parameters - example /admin/mailviewer?notification=WelcomeMail
.
Parameter | Value | Example |
---|---|---|
to= | [email protected] | |
cc= | [email protected] | |
bcc= | [email protected] | |
notification= | class basename of Notification | VerifyEmail |
from= | Carbon | 2 hours ago |
till= | Carbon | yesterday |
around= | Carbon | 2020-12-24 06:00 |
The 'notification' parameter only requires the class basename (ie. \Illuminate\Auth\Notifications\VerifyEmail = VerifyEmail).
The around parameter show all mails sent around the given time. By default is will show all mails sent 10 minutes before and 10 minutes after the given time. You can customize the number of minutes by adding an additional &d=X parameter where X is the number of minutes.
Analytics
To preview the analytics page visit: /admin/mailviewer/analytics
. You can change this url in the config file.
On the analytics page you can view the number of mails sent per Notification and the latest time this notification was sent.
Examples
Example #1
View all VerifyEmail mails to [email protected].
/admin/[email protected]¬ification=VerifyEmail
Example #2
View all mails sent in the last 2 hours.
/admin/mailviewer?from=2 hours ago
Exclusion list
In the config file you can add an array of Notification classes and an array of email addresses that should be excluded. Those notifications and email addresses won't be saved to the database.
Tests
License
All versions of laravel-mailviewer with dependencies
illuminate/auth Version ^11.0
illuminate/routing Version ^11.0
illuminate/support Version ^11.0
illuminate/database Version ^11.0