1. Go to this page and download the library: Download 3xw/attachment-third-party 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/ */
3xw / attachment-third-party example snippets
// Queue
$this->addPlugin('Queue');
return [
'Attachment' => [
//...
'listeners' => [
'beforeSave' => [
'Attachment\Listener\ModifyTypeListener' => [
'type' => 'transit',
'subtype' => 'youtube', // or other third party name
]
],
]
//...
]
];