PHP code example of ognjen / laravel-async-mail
1. Go to this page and download the library: Download ognjen/laravel-async-mail 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/ */
ognjen / laravel-async-mail example snippets
namespace App\Observers;
use App\Order;
use App\Mail\OrderCreated;
use Ognjen\Laravel\AsyncMail;
class OrderObserver {
public function created(Order $order)
{
AsyncMail::send(new OrderCreated($order));
}
}