PHP code example of zipferot3000 / laravel-filepond-adapter

1. Go to this page and download the library: Download zipferot3000/laravel-filepond-adapter 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/ */

    

zipferot3000 / laravel-filepond-adapter example snippets


$schedule->command('fp_adapter:clear --hour=5')->hourly();

Route::group(['middleware' => ['auth:sanctum']], function () {
    ........
    fp_adapter()->getRoutes();
    ........ 
});

fp_adapter()->getFileResponseByUUID(request()); 

fp_adapter()->saveTemporaryFile(request(), auth()->user());

fp_adapter()->destroyTemporaryFile(request(), auth()->user());

fp_adapter()->formatMediaToFilepond($media);

fp_adapter()->moveFiles($files_uuid_array, $new_media_collection_name, $fs_disc_name, $from, $to);

return [

    /*
     * These options set filesystem for save temporary files
     */
    'filesystem' => env('FP_ADAPTER_TEMPORARY_FS', 'temporary'),
    
    /*
     * These options set name of media collection for temporary files
     */
    'media_collection' => env('FP_ADAPTER_MC', 'temporary_files'),
    
    /*
     * These options set custom property name for media object
     */
    'custom_property_name' => env('FP_ADAPTER_CP_NAME', 'file_type'),
    
];
bash
php artisan vendor:publish --provider="Zipferot3000\LaravelFilepondAdapter\FPAdapterServiceProvider"