Youtube for WP is a plugin that enables you to add a new Gutenberg block for listing your latest YouTube videos.
The current version of YoutubeForWP is v0.1.4
. Please refer to the Changelog section for details about previous versions.
In order for the Gutenberg block to function, it is essential to provide your Google API key and activate the "Youtube Data API v3" library on your project.
https://console.cloud.google.com/apis/library/youtube.googleapis.com
Parameter | Type | Description |
---|---|---|
api_key |
string |
Required. Your API key |
If you have direct access to the Google account that owns the YouTube channel, log in to that account. In the top right corner, click on "Settings." In the left-hand side menu, click on "Advanced settings," and you will find your Channel ID.
To target your YouTube channel, we also require your YouTube channel ID.
You have two methods to find it: go to your YouTube channel, display the page source code
(right-click and then View Page Source), search for "channel_id" using "Ctrl F".
You will get multiple results, and the goal is to find a URL with the mentioned ID,
like the one below: "href="https://www.youtube.com/feeds/videos.xml?channel_id=yourcopiedkey">
Parameter | Type | Description |
---|---|---|
channel_id |
string |
Required. Id of channel to fetch videos |
Now that you have this information, go to the WordPress admin panel, navigate to the "Youtube" tab in the sidebar,
and fill in the information in the corresponding fields.
Once you've filled in the inputs, you'll be able to add the Gutenberg block to your posts.
v0.2.0 (Upcoming features)
- Adding WordPress notices for option field validation
v0.1.3
- Refactoring YoutubeRender, function to class
v0.1.1
- Adding test for API
- Adding an error log of type 1 (email notification)
- Adding video data to the youtube_for_wp_rendered_videos filter.
v0.1.0
- Initial version of YoutubeForWP
- Adding a menu to the WordPress administration area (back office) to include option :
- API keys
- YouTube channel ID
- Collecte et stockage des réponses des employés
- Number of videos to retrieve in the Gutenberg block
- Adding a Gutenberg block to display the latest videos from a YouTube channel
- Adding a hook to override the view of the latest videos