PHPackages                             raffaelj/cockpit-videolinkfield - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. raffaelj/cockpit-videolinkfield

ActiveCockpit-module[Utility &amp; Helpers](/categories/utility)

raffaelj/cockpit-videolinkfield
===============================

Video thumbnail downloader from YouTube and Vimeo for Cockpit CMS

0.1.4(5y ago)32511MITPHP

Since Aug 9Pushed 3y ago1 watchersCompare

[ Source](https://github.com/raffaelj/cockpit_VideoLinkField)[ Packagist](https://packagist.org/packages/raffaelj/cockpit-videolinkfield)[ Docs](https://github.com/raffaelj/cockpit_VideoLinkField)[ RSS](/packages/raffaelj-cockpit-videolinkfield/feed)WikiDiscussions master Synced yesterday

READMEChangelogDependencies (1)Versions (3)Used By (1)

VideoLinkField Addon for Cockpit CMS
====================================

[](#videolinkfield-addon-for-cockpit-cms)

**This addon is not compatible with Cockpit CMS v2.**

See also [Cockpit CMS v1 docs](https://v1.getcockpit.com/documentation), [Cockpit CMS v1 repo](https://github.com/agentejo/cockpit) and [Cockpit CMS v2 docs](https://getcockpit.com/documentation/), [Cockpit CMS v2 repo](https://github.com/Cockpit-HQ/Cockpit).

---

Copy a url from YouTube or Vimeo, click the Button "Find Values", wait a second and in the background starts a service, that downloads the video thumbnail and returns some meta data.

It works without a YouTube API key.

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

[](#installation)

Copy this repository into `/addons` and name it `VideoLinkField` or

```
cd path/to/cockpit
git clone https://github.com/raffaelj/cockpit_VideoLinkField.git addons/VideoLinkField
```

Legal advice
------------

[](#legal-advice)

If you don't have the rights to use, download or store the thumbnails, you shouldn't use this addon.

Intended Use
------------

[](#intended-use)

You have your own YouTube or Vimeo channel (or you asked for permission before embedding content from other persons) and you want a simple way to build a privacy friendly website with embedded videos.

But embedding external videos directly is a bad idea for multiple reasons:

1. Privacy - Google tracks my visitors if a YouTube iframe loads videos on startup.
2. EUGDPR - I have to ask my visitors before I can embed third party resources with tracking mechanisms
3. Page speed - If my visitors don't want to see a video, I don't want to load the preview window with 1-2MB

The idea is simple:

Users have a simple UI to copy and paste a video link without taking care of embed snippets. After loading the data from the Wysiwyg field, the link exists, even if users (or search engine bots) disabled javascript. When the document is ready and the visitor accepted cookie usage and third party requests, a script converts the links to iframes.

Features
--------

[](#features)

### Custom Field

[](#custom-field)

- has a preview of the thumbnail
- stores an object with these keys:
    - url
    - text
    - title
    - id
    - provider
    - asset\_id

### TinyMCE Plugin

[](#tinymce-plugin)

It has no thumbnail preview, but it produces a simple html `` tag with all the data I need to embed it dynamically.

Example output:

`Poledance-Show beim Kammgarnspinnereifest 2018`

Settings
--------

[](#settings)

Go to "settings" --&gt; "VideoLinkField" or call `/videolinkfield/settings`.

Now you can define a folder, where all thumbnails should be stored. It works without a folder, too.

Make sure, that you are an admin or to set the rights to manage the addon. Example configuration in `/config/config.yaml`:

```
groups:
    author:
        cockpit:
            backend: true
        videolinkfield:
            manage: true    # Now authors can change the folder
```

You don't have to set up anything for normal usage.

What happens internally?
------------------------

[](#what-happens-internally)

Thumbnails are stored as assets. If title and description are available, they get stored in the assets meta data, too.

### YouTube

[](#youtube)

- two server-side requests to
    - `https://img.youtube.com/vi/VIDEO_ID/0.jpg` to get the thumbnail
    - `https://www.youtube.com/oembed?url=https://www.youtube.com/watch?v=VIDEO_ID&format=json` to get the video title

### Vimeo

[](#vimeo)

- two server-side requests to
    - `http://vimeo.com/api/v2/video/VIDEO_ID.json` to get the thumbnail url, the title and the description
    - and a second one to download the thumbnail

Copyright and License
---------------------

[](#copyright-and-license)

Copyright 2019 Raffael Jesche under the MIT license.

See [LICENSE](/LICENSE) for more information.

###  Health Score

24

—

LowBetter than 32% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity11

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity46

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 ~127 days

Total

2

Last Release

1975d ago

### Community

Maintainers

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

---

Top Contributors

[![raffaelj](https://avatars.githubusercontent.com/u/13042193?v=4)](https://github.com/raffaelj "raffaelj (15 commits)")

---

Tags

cockpityoutubevimeothumbnail download

### Embed Badge

![Health badge](/badges/raffaelj-cockpit-videolinkfield/health.svg)

```
[![Health](https://phpackages.com/badges/raffaelj-cockpit-videolinkfield/health.svg)](https://phpackages.com/packages/raffaelj-cockpit-videolinkfield)
```

###  Alternatives

[hashids/hashids

Generate short, unique, non-sequential ids (like YouTube and Bitly) from numbers

5.5k48.6M278](/packages/hashids-hashids)[norkunas/youtube-dl-php

youtube-dl / yt-dlp wrapper for php

512323.2k15](/packages/norkunas-youtube-dl-php)[aalaap/faker-youtube

Faker provider for generating fake YouTube video URLs

2288.6k](/packages/aalaap-faker-youtube)[light/hashids

Hashids for Yii2

1120.2k](/packages/light-hashids)

PHPackages © 2026

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