{"id":103802,"date":"2019-05-09T02:53:11","date_gmt":"2019-05-09T02:53:11","guid":{"rendered":"https:\/\/wordpress.org\/plugins\/china-video-block\/"},"modified":"2025-10-08T14:23:47","modified_gmt":"2025-10-08T14:23:47","slug":"china-video-block","status":"publish","type":"plugin","link":"https:\/\/bal.wordpress.org\/plugins\/china-video-block\/","author":16276147,"comment_status":"closed","ping_status":"closed","template":"","meta":{"_crdt_document":"","version":"0.2.6","stable_tag":"0.2.6","tested":"6.7.5","requires":"5.0","requires_php":"7.4","requires_plugins":null,"header_name":"China Video Block","header_author":"CNCF (Part of Linux Foundation)","header_description":"Gutenberg block that embeds one video for users in China, another for everyone else.  Useful to accomodate video sites that are blocked in China.","assets_banners_color":"","last_updated":"2025-10-08 14:23:47","external_support_url":"","external_repository_url":"","donate_link":"","header_plugin_uri":"","header_author_uri":"https:\/\/github.com\/cncf\/china-video-block","rating":5,"author_block_rating":0,"active_installs":10,"downloads":13717,"num_ratings":1,"support_threads":0,"support_threads_resolved":0,"author_block_count":0,"sections":["description","installation","changelog"],"tags":{"0.2.0":{"tag":"0.2.0","author":"cjyabraham","date":"2020-01-04 20:40:40"},"0.2.1":{"tag":"0.2.1","author":"cjyabraham","date":"2020-01-04 21:23:50"},"0.2.2":{"tag":"0.2.2","author":"cjyabraham","date":"2020-01-05 16:17:02"},"0.2.3":{"tag":"0.2.3","author":"cjyabraham","date":"2020-01-08 13:29:28"},"0.2.4":{"tag":"0.2.4","author":"cjyabraham","date":"2020-07-08 12:08:35"},"0.2.5":{"tag":"0.2.5","author":"cjyabraham","date":"2021-07-29 20:51:07"},"0.2.6":{"tag":"0.2.6","author":"cjyabraham","date":"2025-10-08 14:23:47"}},"upgrade_notice":[],"ratings":{"1":0,"2":0,"3":0,"4":0,"5":"1"},"assets_icons":[],"assets_banners":[],"assets_blueprints":{},"all_blocks":{"cvb\/block-china-video-block":{"$schema":"https:\/\/schemas.wp.org\/trunk\/block.json","apiVersion":3,"name":"cvb\/block-china-video-block","version":"0.2.6","title":"China Video Block","category":"common","icon":"welcome-view-site","description":"Block that embeds one video for users in China, another for everyone else.","keywords":["china video block","video","youtube"],"supports":{"align":["wide","full"],"anchor":true},"attributes":{"chinavid":{"type":"string"},"worldvid":{"type":"string"}},"textdomain":"china-video-block","editorScript":"file:..\/build\/block.js","editorStyle":"file:..\/build\/block.css","style":"file:..\/build\/style-block.css"}},"tagged_versions":["0.2.0","0.2.1","0.2.2","0.2.3","0.2.4","0.2.5","0.2.6"],"block_files":["\/tags\/0.2.6\/build\/..\/build\/block.js","\/tags\/0.2.6\/build\/..\/build\/block.css","\/tags\/0.2.6\/build\/..\/build\/style-block.css","\/tags\/0.2.6\/src\/..\/build\/block.js","\/tags\/0.2.6\/src\/..\/build\/block.css","\/tags\/0.2.6\/src\/..\/build\/style-block.css"],"assets_screenshots":[],"screenshots":{"1":"China Video block inserted into a post."},"jetpack_post_was_ever_published":false},"plugin_section":[172757,163309],"plugin_tags":[4319,4316,222,1610],"plugin_category":[50],"plugin_contributors":[201780,171210],"plugin_business_model":[],"class_list":["post-103802","plugin","type-plugin","status-publish","hentry","plugin_section-block","plugin_section-blocks","plugin_tags-china","plugin_tags-chinese","plugin_tags-video","plugin_tags-youtube","plugin_category-media","plugin_contributors-bonkerz","plugin_contributors-cjyabraham","plugin_committers-cjyabraham"],"banners":[],"icons":{"svg":false,"icon":"https:\/\/s.w.org\/plugins\/geopattern-icon\/china-video-block.svg","icon_2x":false,"generated":true},"screenshots":[],"raw_content":"<!--section=description-->\n<p>\ud83c\udde8\ud83c\uddf3 \ud83c\udfac \ud83e\uddf1 This 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.<\/p>\n\n<p>The plugin has been developed for <a href=\"https:\/\/www.cncf.io\/\">CNCF<\/a> and <a href=\"https:\/\/www.linuxfoundation.org\/\">The Linux Foundation<\/a>.<\/p>\n\n<p>For more information on how to develop this block, please see the <a href=\"https:\/\/github.com\/cncf\/china-video-block\">github repo<\/a>. PRs are welcome.<\/p>\n\n<!--section=installation-->\n<ol>\n<li>Upload the plugin files to the <code>\/wp-content\/plugins\/china-video-block<\/code> directory, or install the plugin through the WordPress plugins screen directly.<\/li>\n<li>Activate the plugin through the 'Plugins' screen in WordPress<\/li>\n<li>Use the Settings-&gt;China Video Block screen to set the IPInfo.io token<\/li>\n<li>Insert the block into a post or page.<\/li>\n<\/ol>\n\n<!--section=changelog-->\n<h4>0.2.6<\/h4>\n\n<ul>\n<li>WordPress 6.7 compatibility<\/li>\n<li>Plugin build modernisation<\/li>\n<\/ul>\n\n<h4>0.2.5<\/h4>\n\n<ul>\n<li>Fixes PHP Notice \"Trying to access array offset on value of type bool\"<\/li>\n<li>WordPress 5.8 compatibility<\/li>\n<\/ul>\n\n<h4>0.2.4<\/h4>\n\n<ul>\n<li>Loads the front-end script using wp_enqueue_script() only when the block is present on the page<\/li>\n<\/ul>\n\n<h4>0.2.3<\/h4>\n\n<ul>\n<li>Fixed the ver number on the script so that the block doesn't keep breaking<\/li>\n<\/ul>\n\n<h4>0.2.2<\/h4>\n\n<ul>\n<li>added a browser-busting version querystring for the front.js file so that browsers download the new file when it updates<\/li>\n<\/ul>\n\n<h4>0.2.1<\/h4>\n\n<ul>\n<li>added compiled build file<\/li>\n<\/ul>\n\n<h4>0.2.0<\/h4>\n\n<ul>\n<li>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<\/li>\n<li>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<\/li>\n<\/ul>\n\n<h4>0.1.0<\/h4>\n\n<ul>\n<li>First release<\/li>\n<\/ul>","raw_excerpt":"\ud83c\udde8\ud83c\uddf3 \ud83c\udfac \ud83e\uddf1 Automatically serve China-hosted videos to Chinese audiences while delivering YouTube videos to viewers from other regions.","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/bal.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin\/103802","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/bal.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin"}],"about":[{"href":"https:\/\/bal.wordpress.org\/plugins\/wp-json\/wp\/v2\/types\/plugin"}],"replies":[{"embeddable":true,"href":"https:\/\/bal.wordpress.org\/plugins\/wp-json\/wp\/v2\/comments?post=103802"}],"author":[{"embeddable":true,"href":"https:\/\/bal.wordpress.org\/plugins\/wp-json\/wporg\/v1\/users\/cjyabraham"}],"wp:attachment":[{"href":"https:\/\/bal.wordpress.org\/plugins\/wp-json\/wp\/v2\/media?parent=103802"}],"wp:term":[{"taxonomy":"plugin_section","embeddable":true,"href":"https:\/\/bal.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_section?post=103802"},{"taxonomy":"plugin_tags","embeddable":true,"href":"https:\/\/bal.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_tags?post=103802"},{"taxonomy":"plugin_category","embeddable":true,"href":"https:\/\/bal.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_category?post=103802"},{"taxonomy":"plugin_contributors","embeddable":true,"href":"https:\/\/bal.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_contributors?post=103802"},{"taxonomy":"plugin_business_model","embeddable":true,"href":"https:\/\/bal.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_business_model?post=103802"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}