PHP code example of robertseghedi / laravel-notification-system

1. Go to this page and download the library: Download robertseghedi/laravel-notification-system 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/ */

    

robertseghedi / laravel-notification-system example snippets


 // your providers

RobertSeghedi\LNS\LNSProvider::class,
 

use RobertSeghedi\LNS\Models\LNS;
  

public function monday_alert($user = null)
{
    $notification = LNS::notify($user, "Your package will arrive on Monday.");
    if($notification) return redirect()->back()->with('success', 'Notification sent.');
}

public function delete($notification)
{
    $deletion = LNS::delete($notification);
    if($deletion) return redirect()->back();
}
config/app.php

  php artisan migrate