diff --git a/lib/client-assets.php b/lib/client-assets.php index 5e37b931a93b8..20caf75b0f015 100644 --- a/lib/client-assets.php +++ b/lib/client-assets.php @@ -502,6 +502,12 @@ function gutenberg_extend_wp_api_backbone_client() { wp_json_encode( $schema_response->get_data() ) ), 'before' ); } + + /* + * For API requests to happen over HTTP/1.0 methods, + * as HTTP/1.1 methods are blocked in a variety of situations. + */ + wp_add_inline_script( 'wp-api', 'Backbone.emulateHTTP = true;', 'before' ); } /**