Pro editor changes not save

We are facing an issue with the “Pro” theme, when we change some text and save it using a pro editor it was not saved and showing previous revision after a refresh. Please check the loom video https://www.loom.com/share/d940383088514719bc57ce828407fff4 for more details. The first issue “Leave a site” popup described in the loom video was fixed after the WordPress update, but the second issue remains exists.

We have tried the below things in order to debug the issue:

  • We have deactivated all the plugins and checked the issue and found that it is not resolved.

  • Currently, the child theme is activated. For testing purposes, we have activated the parent “Pro” theme and checked the issue, and found that it is not resolved.

Could you please help us to resolve the issue?

Note: We have recently updated the PHP version to 7.4 and this issue occurred.

Please check with the help of the staging site: https://17911900-wgiorg.pantheonsite.io/

Any update on this?

Hello @designext,

Thanks for writing to us

It might be the issue is a cache or version compatibility issue . I would suggest you troubleshoot with a few of the common issues before we investigate your settings.

  1. Testing For Theme Related Issue
  2. Testing For Plugin Conflict
  3. Theme Update
  4. Child Theme
  5. Css/Js Customization
  6. Increasing Php Memory Limit
  7. Disabling Cache
  8. Disabling Cdn
  9. Permalinks
  10. Version Compatibility

If it doesn’t work for you, please share your details in a secure note. Please provide the following details

  • WordPress Login URL
  • Admin level username and password
  • Exact page URL
    FTP Details

You can find the Secure Note button at the bottom of your posts

Thanks

Hello Prakash,

We have done all the suggested points but the issue is not resolved. I have shared the site details with you using the “Secure Note” option. Please check and help us to resolve the issue.

Hi @designext,

I have checked your site and found my colleague was correct and the Pantheon Advanced Page Cache plugin is the reason behind your issue. I went ahead and cleared the cache from Settings > Pantheon Page Cache and found the changes in the Content Builder.

Hope it helps.
Thanks

@tristup – We have checked the issue by clearing the cache but the issue remains exists. Please check this loom video https://www.loom.com/share/a6b040178c4647579e9335b407cee723 for more details. In this loom video when we add some text it was displayed on the frontend but not visible in the backend(Pro Editor).

Hi @designext,

I have checked it again and followed the same steps you described in your video and refreshed the browser by choosing the Empty Cache and Hard Reload option shown in the screenshot and found the updated text. I would also suggest you decrease the Maximum time for the cached page.

Hope it helps.
Thanks

We are checking with the server support if anything comes up we will let you know.

Great!
Our staff will be on standby.

We have discussed the issue with the Pantheon server support and got the below reply, please check:

Hello again,

I have reviewed the video you’ve sent over last week and I see what you mean. There is certainly an element of caching involved but please note that the must-use plugin is part of our WP upstream: https://github.com/pantheon-systems/WordPress/tree/default/wp-content/mu-plugins/pantheon. We’ve not had other seemingly related customer-reported issues regarding this must-use plugin. I would not recommend disabling it and instead, try reverting the PHP version on this one multidev.

Looking over the PHP error logs, I am seeing some PHP warnings for the theme’s visual composer:

[26-Mar-2021 14:27:15 UTC] PHP Warning: Unable to load content from post. in /code/wp-content/themes/pro/cornerstone/includes/classes/elements/class-element-front-end.php on line 113 [26-Mar-2021 14:27:37 UTC] PHP Warning: Unable to load content from post. in /code/wp-content/themes/pro/cornerstone/includes/classes/elements/class-element-front-end.php on line 113

You may want to relay the above PHP warning to the theme developer to see if this is a known issue.

I also am not able to create a mutlidev to test things as the current multidev allotment has been exhausted.

Jen D.
Sr. Customer Success Engineer
Pantheon Systems, Inc

Can you please check the errors showing in the above comment and let us know, do these errors causing an issue with the Pro editor?

Hi @designext,

Regarding the error, I don’t think that is is relevant. It could be another caching issue if a page was deleted.


I believe I was able to correct this issue on your site and identify the underlying cause. When a page is loaded in the Pro editor we make a request to the WordPress JSON API. The URL looks something like this (12345 is the Page ID)

example.com/wp-json/themeco/data/content/12345

The response contains all the data needed to show the page in the builder. By default, WordPress doesn’t cache those responses, but Pantheon is caching them - probably at some level outside our control like in the server configuration itself (not anywhere in WordPress). However, in the theme, just before we send that response, we can signal to the webserver that we would like to avoid caching it.

I’ve done this temporarily by directly modifying Pro on your site. Take a look now and it should be working. We’re going to push the next update as early as next week and it will include extra code to explicitly request not to cache those routes which will make Pro more stable in environments that deviate from the WordPress defaults like Pantheon. You can safely update to that version when it’s available.

Hi Alexander,

We have checked the issue on the staging site and it is not resolved yet. Can you please check it again?

Just for your information, we have given staging site credentials in a secure note.

Hi @designext,

I just checked it again and I’m seeing some requests are still getting cached. It appeared to be working when I tested it the other day but maybe it wasn’t.

By default WordPress sends an HTTP header that disables browser caching Cache Control: no-cache, must-revalidate, max-age=0 on all JSON API requests that happen when a user is logged in. Pantheon must be overriding this somehow.

Can you ask them to advise why logged in requests to the WordPress JSON API are getting cached? This is not how plugin/theme developers would expect WordPress to behave as it prohibits actually using the JSON API for anything that needs to be done in realtime with a user session.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.