Layout Disappears After Save When Using Looper (Pro 6.6.8, WP 6.8.1, Multisite, WP Engine)

Hi team,

I’m running into an issue I can’t seem to resolve. I’m using the latest versions of both WordPress (6.8.1) and Pro (6.6.8) on a multisite installation hosted on WP Engine.

The problem happens when editing a Layout. After saving, I go to the front end and see that the posts are reverting to the default template. Then when I go back into the back end and refresh, the layout disappears completely.

Here’s what I’ve observed and tried:

I originally saved the Layout as a Template, so I tried rebuilding by importing the template back into the Layout. Same issue: once I save, the Layout disappears.

If I rebuild the Layout entirely from scratch, it works fine until I add a Looper. After adding a Looper and saving, the Layout vanishes again and the post defaults back to the regular template.

Following advice from other forum threads, I’ve excluded /cornerstone/ from both WP Engine’s cache and Cloudflare CDN caching, but the problem persists.

It seems tied directly to adding a Looper to the Layout. Without a Looper, the Layout saves and renders fine. With a Looper, it disappears upon save.

I would appreciate any help or suggestions.

Thanks in advance!

Hey @gavn8r,

Thanks for writing in! I was checking the layouts and I am seeing this:

I wonder which layout you are experiencing with the issue. Be advised that when building custom archive layouts, you do not need a Looper Provider. Only the Looper Consumer is needed in an archive layout so the post items will display. The custom archive will use the default WordPress loop in displaying the items when the layout is assigned to a tag, category or any particular archive page.

Hope this makes sense.

My issue is in Article Page - General.

Thanks for letting me know about the archive layouts.

Hey @gavn8r,

Is this the layout template that you want to load for your custom single layout?

  • See the secure note below

I was wonder where you added a Looper Provider in any of these elements.

Thanks.

Thanks for showing me that it worked for you. On this layout, the only loop is where I show the categories at the top of the page. It has a Looper Provider in there.

Seeing that it worked for you, I tried it again myself and it didn’t work. But then I thought, what if there’s something wrong with my account? So, I logged in with a backup user account and tried it. It worked this time. The layout didn’t disappear on refresh. So, maybe my user account has something wrong with it?

Hello @gavn8r,

Thanks for the update.

Good to know that it’s working for you now. It might have been a cache or permission issue, but we can’t say for sure. We recommend deleting the user that is not working and recreate it again.

Let us know if the issue occurs again.

Best regards,

Will do. Thanks again.

Hello @gavn8r,

Please let us know how it goes.

Thanks