[Resolved] Still unable to create content template – critical error
This support ticket is created 3 years, 10 months 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.
No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.
As Jamal observed in the other ticket, the options recording the details of the saved templates was wrong, the ID of the stored template was not of the template post type.
I don't know how a template might have been saved with the wrong post type, but I notice you have two plugins installed for switching post types, so I suspect it may have been accidentally updated.
In any case, I simply deleted the option, which fixes the errors. I then created a new template for Books which I was able to save without issue, so it looks like the problem is resolved.
I watched the video, and I see that the fix failed on your server.
And went back to your server and did some more testing.
On inspecting the database I saw that the problem actually occurs on your site because the templates, which are saved as posts, are missing a value for post_type (which should be 'view-template').
When I manually set the value, the template showed up in the list and worked as normal.
When I edited it and re-saved it, the post type was lost again.
Well, as I said before, you have two post type switcher plugins on your site, and "Custom Post Type Changer" was active.
So I disabled the plugin, reset the value for the content template post type in the database, and lo and behold, everything works as expected.
I also tested creating a template for books, no problem.
I couldn't see any settings pages for that plugin. I suggest you stop using it, and maybe use the other more mature plugin created by a WP core contributor instead.