create custom artisan command laravel
php artisan make:command SendEmail
create custom artisan command laravel
php artisan make:command SendEmail
laravel create command tutorial
Artisan::command('build {project}', function ($project) {
$this->info("Building {$project}!");
})->describe('Build the project');
laravel create command tutorial
use App\Models\User;
use App\Support\DripEmailer;
Artisan::command('email:send {user}', function (DripEmailer $drip, $user) {
$drip->send(User::find($user));
});
laravel create command tutorial
/**
* The name and signature of the console command.
*
* @var string
*/
protected $signature = 'email:send {user} {--queue}';
laravel create command tutorial
php artisan email:send 1 --queue
Copyright © 2021 Codeinu
Forgot your account's password or having trouble logging into your Account? Don't worry, we'll help you to get back your account. Enter your email address and we'll send you a recovery link to reset your password. If you are experiencing problems resetting your password contact us