Skip Navigation

[Resolved] How to bulk unassign Layouts templates from many individual posts

This thread is resolved. Here is a description of the problem and solution.

Problem:
A template Layout is individually assigned to very many posts (rather than simply being assigned to the post type).

Now that the client wants to remove the assignment, the UI only allows to un-assign up to 5 at a time, and there are 100s.

Solution:
Create a dummy Layout. Assign it to the post type in question to be used for single posts. Then un-assign the Layout from the post type. The dummy Layout can now be discarded.

This support ticket is created 6 years, 1 month ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 7:00 – 14:00 7:00 – 14:00 7:00 – 14:00 7:00 – 14:00 7:00 – 14:00 -
- 15:00 – 16:00 15:00 – 16:00 15:00 – 16:00 15:00 – 16:00 15:00 – 16:00 -

Supporter timezone: Europe/London (GMT+00:00)

This topic contains 2 replies, has 2 voices.

Last updated by barbaraB-2 6 years, 1 month ago.

Assisted by: Nigel.

Author
Posts
#1165864
Screen Shot 2018-12-13 at 8.30.19 PM.png

I am trying to: Create an archive layout for posts

Link to a page where the issue can be seen: hidden link

I expected to see: A way to delete this layout but i can't because 15,000+ posts are assigned to it, and I can only remove 5 at a time. I tried deleting the layouts module, clearing the cache and reinstalling, but it is still showing the same thing.

Instead, I got:

#1166195

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+00:00)

Hi there

I understand you have many posts where a Layout is individually assigned to them (rather than being assigned to the entire post type), so that to un-assign them you have to do it individually or in small batches.

When you assign a Layout to a post type it gets used for all posts of that type. If you un-assign the Layout, it is removed from all the posts of that type.

So that's what you can do here.

Create a new dummy Layout that you will later dispose of, doesn't matter what content it has, then assign it to the post type in question, so that it is used for all posts of that type. Then change its usage and un-assign it from the post type.

All of the posts of that type should then have no Layout assigned.

Can you try that and confirm it works?

#1167247

My issue is resolved now. Thank you!