Skip Navigation

[Resolved] Views saving "Preview" Posts for each view, and a real View

This support ticket is created 3 years, 7 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.

This topic contains 2 replies, has 2 voices.

Last updated by smileBeda 3 years, 7 months ago.

Author
Posts
#1790401
Screenshot 2020-09-25 at 19.52.58.png

When View creates (block) views it creates a Post of type view "viewname-preview-number" and a post of type view "viewnamehere" and a post of type wpa-helper.
See screenshot.

For each View it does that.
I have on my website no more than 3 views, in the database, I have many.

For example I have a view (an archive actually) called "bulletins"
See the scnreeshot, Toolset also created a post "bulletins-preview-1600670134"
The preview is always a draft, the other is published.

This clutters the database with duplicate entries.
As if it would not be enough, Views also creates a wpa-helper post for each archive, on top of above duplication and pendant post of type view
This makes it in fact 3 posts each thing Toolset does call "View", or "Archive"

Can we avoid it please?

I mean, sarcastically said, I am not really surprised the servers choke under Views, if we look at above detail.
I could imagine that an AJAX call is made to each post every time the automatic "save" process of blocks is happening. 3 times instead of 1. Then in a view you may have RFG, so probable that there are 3 more calls just for that post? Then a field, in that view, will probably be enough already to make the server stop delivering answers.

#1790551

Nigel
Supporter

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

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

I know from a recent ticket that those are required, and if you delete them they will need to be recreated to make it possible to edit the archives and Views. It's related to being able to edit them with the block editor, though I don't know the details of why.

I'm not sure how this would have much of an impact on a site. Your site may have 2000 posts, but probably only has a handful of Views or achives, and so even with the duplicate entries that has very little impact on the overall size of the wp_posts table.

#1791081

It is not creating thousands of posts, right.

I found this because 2 reasons:
- Checking why servers slow down as soon views are used on the contents
- why sometimes wrong views templates are called (slug) in the code that I renamed.

I was aware of wpa-helper post which basically holds the 2 ShortCodes that render view search and loop
I wasn’t aware of copies created for trashed views, and doubles of existing views for only preview and thought it might be a error

Since it’s expected I close here in hopes that database resources could be maybe considered in future. In that database I have 300 posts displaying in 4 archives and a RFG view/post view respectively

So each 6 things I seem to get like 18 things in the database.
That’s 300% of what I actually see in the GUI or front end and I think it can be improved.

It’s not that these are revisions or so.

Thanks!

This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.