该插件尚未通过WordPress的最新3个主要版本进行测试。 当与较新版本的WordPress一起使用时,可能不再受到维护或支持,并且可能会存在兼容性问题。

China Video Block

描述

🇨🇳 🎬 🧱 This Gutenberg block allows for embedding a video in a WordPress post or page. If the user who views the page is in China, a different video will show from users in the rest of the world. This is to appropriately deal with China’s Internet wall which blocks YouTube and other video platforms.

For more information on how to develop this block, please see the github repo.

The plugin has been developed for CNCF and The Linux Foundation.

屏幕截图

  • China Video block inserted into a post.

区块

该插件提供了1个区块.

  • China Video Block

安装

  1. Upload the plugin files to the /wp-content/plugins/china-video-block directory, or install the plugin through the WordPress plugins screen directly.
  2. Activate the plugin through the ‘Plugins’ screen in WordPress
  3. Use the Settings->China Video Block screen to set the IPInfo.io token
  4. Insert the block into a post or page.

评价

2019年8月2日
If you're working on optimizing your website for Chinese-based customers - this is a great plugin the simplifies the ability to have a fallback to a non-YouTube video so your Chinese customers could have the same experience as others. Also, the support was fantastic! Great developer!
阅读所有1条评价

贡献者及开发者

“China Video Block” 是开源软件。 以下人员对此插件做出了贡献。

贡献者

“China Video Block”插件已被翻译至2种本地话语言。 感谢所有译者为本插件所做的贡献。

将“China Video Block”翻译成您的语言。

对开发感兴趣吗?

您可以浏览代码,查看SVN仓库,或通过RSS订阅开发日志

更新日志

0.2.5

Fixes PHP Notice “Trying to access array offset on value of type bool”
WordPress 5.8 compatibility

0.2.4

  • loads the front-end script using wp_enqueue_script() only when the block is present on the page

0.2.3

  • fixed the ver number on the script so that the block doesn’t keep breaking

0.2.2

  • added a browser-busting version querystring for the front.js file so that browsers download the new file when it updates

0.2.1

  • added compiled build file

0.2.0

  • rewrite of the code to favor the China video; the problem was that, when favoring the non-China video, it would produce a failed request for users in China since it was loaded on page load before being changed to the China video
  • when the ipinfo call produces and error, no cookie value is now set so that the call can be tried again during a subsequent page load

0.1.0

  • First release