“Unable to communicate back with site to check for fatal errors…”
-
Hi!
I’m afraid that my main problem is that I don’t really know a lot of PHP and jQuery and I started coding again after a LONG time. I used to use an Underscores basis to build my own WordPress custom theme, tweaking the CSS a bit, but never really adding PHP or jQuery functions to it. Now I decided to step up my game and start doing legible and responsive CSS layouts, with a bit of jQuery. I updated WordPress from version 5.0.4 to 5.2, installed a local copy of it, and started working. Occasionally, my local installation would not allow me to edit the theme .php files in the live editor, giving me a nonce_failure() error. Eventually, I finished working, uploaded the revised theme in my live WP installation… and I was completely unable to edit .php files with the theme editor. This is the error it gave me:
“Unable to communicate back with site to check for fatal errors, so the PHP change was reverted. You will need to upload your PHP file change by some other means, such as by using SFTP”.
This occurs even whe I switch to other themes and try to edit them.
Read a bit about the issue online, but, before jumping to conclusions, I assumed it was a matter of bad coding on my part. I installed “Health Check & Troubleshooting”, and ran it to have some diagnostics. That’s what I got:
“When switching the active theme to [my custom theme], a site failure occurred. Because of this we reverted theiot theme to the one you used previously”
Assuming bad coding again, I searched for best practices and discovered that you shouldn’t include any raw jQuery and/or Google fonts reference in your theme, so I coded Google fonts and jQuery into proper PHP functions, putting my jQuery code in a separate .js file. Ran diagnostics again… same errors. Except that I carefully kept track of all the edits in my local WP installation… and local copy works absolutely fine now. So my theme is not badly coded now? What am I doing wrong? Is it my web host? Is it my code? What can I do? Is this explanation a mess? XD
The page I need help with: [log in to see the link]
- The topic ‘“Unable to communicate back with site to check for fatal errors…”’ is closed to new replies.