Gutenberg Insecure Requests and Editor errors

Post a reply


This question is a means of preventing automated form submissions by spambots.
Smilies
:D :) ;) :( :o :shock: :? 8-) :lol: :x :P :oops: :cry: :evil: :twisted: :roll: :!: :?: :idea: :arrow: :| :mrgreen: :geek: :ugeek:

BBCode is ON
[img] is ON
[url] is ON
Smilies are ON

Topic review
   

If you wish to attach one or more files enter the details below.

Maximum filesize per attachment: 1 MiB.

Expand view Topic review: Gutenberg Insecure Requests and Editor errors

Gutenberg Insecure Requests and Editor errors

by axew3 » Fri May 03, 2024 9:15 am

At date of this post, to fix the fact that the Gutenberg return (console) errors about insecure requests and suddenly cause the stop of the editor interface loading, and do not work in several ways, the fix to apply would be like this:

open the file
/wp-admin/admin-header.php
and just after this starting code:

Code: Select all

<?php
/**
 * WordPress Administration Template Header
 *
 * @package WordPress
 * @subpackage Administration
 */
add the follow line:

Code: Select all

header('Content-Security-Policy: upgrade-insecure-requests');
replace the old file with the new updated.

I did not reversed the problem from where it come out (why the js resource was loaded as http and not https causing the Gutenberg malfunction) and that disappeared after (so i cannot imagine anymore from where it was coming out) when the editor loaded good, after the above applied fix. Seem that once the fix has been applied and you load the editor, and then you update the template, all return to work: maybe it was something wrongly cached that goes fixed automatically.

Top