PHP code example of codezone / filament-mediazone

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

    

codezone / filament-mediazone example snippets


use Codezone\MediaZone\MediaZonePlugin;

public function panel(Panel $panel): Panel
{
    return $panel
        ->plugins([
            MediaZonePlugin::make(),
        ]);
}

'media' => [
    'driver' => 'local',
    'root'   => storage_path('app/public/media'),
    'url'    => env('APP_URL').'/storage/media',
    'visibility' => 'public',
],

use Codezone\MediaZone\Forms\Components\MediaPicker;

MediaPicker::make('image_id')
    ->label('Featured Image'),
bash
php artisan vendor:publish --tag=mediazone-migrations
php artisan migrate
bash
php artisan vendor:publish --tag=mediazone-config
bash
php artisan filament:assets