PHPackages                             3xw/attachment-third-party - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. 3xw/attachment-third-party

ActiveCakephp-plugin

3xw/attachment-third-party
==========================

CakePHP utils plugins

3.0.2(6y ago)09PHPPHP &gt;=5.5.9

Since May 14Pushed 6y ago1 watchersCompare

[ Source](https://github.com/3xw/attachment-third-party)[ Packagist](https://packagist.org/packages/3xw/attachment-third-party)[ RSS](/packages/3xw-attachment-third-party/feed)WikiDiscussions master Synced yesterday

READMEChangelog (3)Dependencies (4)Versions (4)Used By (0)

attachment-third-party plugin for CakePHP
=========================================

[](#attachment-third-party-plugin-for-cakephp)

Attachment third pary ( Youtube etc ... ). Is a sub project of plugin 3xw/attachment

Installation
------------

[](#installation)

You can install this plugin into your CakePHP application using [composer](http://getcomposer.org).

The recommended way to install composer packages is:

```
composer require 3xw/attachment-third-party
```

### Add Queue tasks

[](#add-queue-tasks)

Acrtive the plugin in your Application.php file:

```
// Queue
$this->addPlugin('Queue');
```

Then migrate the db

```
bin/cake migrations migrate -p Queue
```

Google
------

[](#google)

### Install

[](#install)

Install Google lib:

```
composer require google/apiclient:^2.0
```

### Protect

[](#protect)

Ignore your Google private settings. Add following in .gitignore file:

```
/config/google/*
```

### OAuth

[](#oauth)

- select/create a Google project [here](https://console.developers.google.com/apis/dashboard)
- active Youtube Library in library menu
- create and download a OAuth Client (of type "Other"), place it as config/google/credentials.json

Usage
-----

[](#usage)

### Prepare

[](#prepare)

When using attachment, setup an event listener either:

- globally in your config/attachment.php

```
return [
	'Attachment' => [

		//...

		'listeners' => [
			'beforeSave' => [
				'Attachment\Listener\ModifyTypeListener' => [
					'type' => 'transit',
					'subtype' => 'youtube', // or other third party name
				]
			],
		]

		//...

	]
];
```

- specifically in any template:

```
$this->Attachment->buildIndex([
	'actions' => ['add','edit','delete','view'],
	'types' =>['image/jpeg','image/png','embed/youtube','embed/vimeo','video/quicktime','transit/youtube'],
	'listeners' => [
		'beforeSave' => [
			'Attachment\Listener\ModifyTypeListener' => [
				'type' => 'transit',
				'subtype' => 'youtube',
			]
		],
	]
])
```

### Move Files

[](#move-files)

By creating a cron tasks, the plugin will look for attachments with a type "transit" and create Queue tasks for each attachment with relevant Mover Class.

```
bin/cake queue add CreateTransitStack & bin/cake queue runworker
```

###  Health Score

24

—

LowBetter than 32% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity4

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity56

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~1 days

Total

3

Last Release

2554d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/e3a1da2aecf796ac1e96bcf4ca27b43c140f29c91e90f7e24eaf7f8cb0ff9507?d=identicon)[awallef](/maintainers/awallef)

---

Top Contributors

[![awallef](https://avatars.githubusercontent.com/u/1070992?v=4)](https://github.com/awallef "awallef (11 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/3xw-attachment-third-party/health.svg)

```
[![Health](https://phpackages.com/badges/3xw-attachment-third-party/health.svg)](https://phpackages.com/packages/3xw-attachment-third-party)
```

###  Alternatives

[friendsofcake/cakepdf

CakePHP plugin for creating and/or rendering Pdfs, several Pdf engines supported.

3752.1M3](/packages/friendsofcake-cakepdf)[cakephp/bake

Bake plugin for CakePHP

11211.2M158](/packages/cakephp-bake)[dereuromark/cakephp-tools

A CakePHP plugin containing lots of useful and reusable tools

338920.1k32](/packages/dereuromark-cakephp-tools)[dereuromark/cakephp-queue

The Queue plugin for CakePHP provides deferred task execution.

308850.3k14](/packages/dereuromark-cakephp-queue)[dereuromark/cakephp-ide-helper

CakePHP IdeHelper Plugin to improve auto-completion

1862.1M27](/packages/dereuromark-cakephp-ide-helper)[dereuromark/cakephp-tinyauth

A CakePHP plugin to handle user authentication and authorization the easy way.

129228.6k10](/packages/dereuromark-cakephp-tinyauth)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
