https://github.com/juzaweb/email-template
Add and manager email template for Laravel
https://github.com/juzaweb/email-template
email-sender email-template email-template-for-laravel email-template-laravel laravel-email-template manager-email-template
Last synced: 3 months ago
JSON representation
Add and manager email template for Laravel
- Host: GitHub
- URL: https://github.com/juzaweb/email-template
- Owner: juzaweb
- Created: 2021-03-28T10:38:11.000Z (about 4 years ago)
- Default Branch: master
- Last Pushed: 2021-04-30T14:31:56.000Z (about 4 years ago)
- Last Synced: 2025-02-07T21:19:51.503Z (4 months ago)
- Topics: email-sender, email-template, email-template-for-laravel, email-template-laravel, laravel-email-template, manager-email-template
- Language: PHP
- Homepage:
- Size: 21.5 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
## About
Add and manager email template for Laravel### Features
- [x] Email template table
- [x] Add/Edit/Manager email template
- [x] Mail list send history
- [x] Send mail with cronjob## Install
- Install package
```
composer require tadcms/laravel-email-template
```- Migration
```
php artisan migrate
```- Setup The Scheduler: Add command to your server
```
* * * * * cd /path-to-your-project && php artisan schedule:run >> /dev/null 2>&1
```View more: [Starting The Scheduler](https://laravel.com/docs/6.x/scheduling#introduction)
## Usage
### Make Email Template
```
use Tadcms\EmailTemplate\Models\EmailTemplate;EmailTemplate::create([
'code' => 'test_mail',
'subject' => 'Send email test for {name}',
'body' => 'Hello {name},
This is the test email
',
'params' => [
'name' => 'Your Name',
],
]);
```### Send email with template
```
use Tadcms\EmailTemplate\EmailService;EmailService::make()
->withTemplate('test_mail')
->setEmails('[email protected]')
->setParams([
'name' => 'The Anh',
])
->send();
```## License
The package is open-sourced software licensed under the [MIT license](https://opensource.org/licenses/MIT).