PHP code example of linking / flashr

1. Go to this page and download the library: Download linking/flashr 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/ */

    

linking / flashr example snippets



        use Linking\Flashr\FlashrServiceProvider;
        use Illuminate\Support\ServiceProvider;

        class AppServiceProvider extends ServiceProvider
        {
            /**
             * Bootstrap any application services.
             *
             * @return void
             */
            public function boot()
            {
                // ...
                $this->app->register(FlashrServiceProvider::class);
            }
         
        }


    'providers' => [
    
        // ...

         \Linking\Flashr\FlashrServiceProvider::class,

    ];


    'aliases' => [
    
        // ..
        'Flashr' => \Linking\Flashr\Facades\Flashr::class,
        // ..
    
    ];


public function edit(Post $post) {
    Flashr::success("The post has been edited");
    return view('post.edit', compact('post'));
}

php artisan vendor:publish --tag=flashr