Download the PHP package alleyinteractive/wp-video-sync without Composer
On this page you can find all versions of the php package alleyinteractive/wp-video-sync. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download alleyinteractive/wp-video-sync
More information about alleyinteractive/wp-video-sync
Files in alleyinteractive/wp-video-sync
Package wp-video-sync
Short Description Sync videos from a hosting provider to WordPress
License GPL-2.0-or-later
Homepage https://github.com/alleyinteractive/wp-video-sync
Informations about the package wp-video-sync
WP Video Sync
Contributors: alleyinteractive
Tags: alleyinteractive, wp-video-sync
Stable tag: 0.1.0
Requires at least: 6.0
Tested up to: 6.6
Requires PHP: 8.2
License: GPL v2 or later
Sync videos from a hosting provider to WordPress.
Runs a scheduled task to sync videos from a supported video hosting provider to WordPress in batches based on the last modified date of the video. Implementers are responsible for installing and configuring a compatible plugin, choosing it as an adapter, and defining the callback that will be run for each video, which will be responsible for performing any post creations or updates in WordPress.
This plugin is a great way to sync videos uploaded to a hosting provider (such as JW Player) to WordPress, such that the video itself remains on the hosting provider, but the video can be displayed in WordPress using a player block or shortcode, appears at its own unique URL, and can be included in search results.
Installation
You can install the package via Composer:
Usage
Activate the plugin in WordPress and use it like so:
This will configure the plugin to import a batch of 1000 videos every hour from JW Player, sorted by least to most recently updated, starting with the date and time of the last video that was updated. If videos have already been imported (as identified by the postmeta value saved for the unique video ID) they will be updated rather than created. New videos will be created. The example code above uses the post
post type for this purpose, but the code could easily be adapted to use a custom post type. Additionally, the post content could be set to include a Gutenberg block or a shortcode for a player.
Supported Adapters
As of now, the plugin only supports JW Player 7 for WordPress (both the free and premium versions). Other adapters may be added in the future.
JW Player 7 for WordPress
- Requires the JW Player 7 for WordPress plugin to be installed, activated, and properly configured with access credentials. Also supports the premium version.
- The video object in the callback is a
stdClass
with the properties described in themedia
object under response code200
in the JW Player API documentation for the media list endpoint.
Releasing the Plugin
New versions of this plugin will be created as releases in GitHub once ready.
Changelog
Please see CHANGELOG for more information on what has changed recently.
Credits
This project is actively maintained by Alley Interactive. Like what you see? Come work with us.
- Alley
- All Contributors
License
The GNU General Public License (GPL) license. Please see License File for more information.