I was told to try disabling other plugins and see if the DB issue is resolved, however, it is not. hidden link has still issue with filtering and there are only 2 plugins enabled - Toolset types & ACF.
Interesting thing is that the WP backend (post edit page) and the front-end of the post show the same author (connected custom post type), the only issue is the filtering, it shows the posts of another author when performing filtering (and has the wrong connection ID in the DB). However, during the manual fixes of those connection in the DB, other posts are reassigned randomly to another author.
Please investigate.
Hi,
Thank you for contacting us and I'd be happy to assist.
Your website seems to be served through the Cloudflare CDN and your host WPEngine also applies its own cache and optimizations.
It is possible that you're seeing older cached results from filtering? I'll recommend checking that, after clearing all involved caches.
Also when you say "manual fixes of those connection in the DB" do you mean making direct changes to the database? It is never recommended.
If the issue still persists, you're welcome to share temporary admin login details, along with the exact steps for how and where the incorrect filtering can be seen.
Note: Your next reply will be private and please make a complete backup copy, before sharing the access details.
regards,
Waqar
Thank you for sharing the admin access.
During troubleshooting, I noticed that the website is using a PHP template file "archive-blog_post.php" for the custom search/filtering of posts on the blog page.
Is there any reason why you're not using Toolset's WordPress Archive feature for creating the search/filtering of posts?
( ref: https://toolset.com/course-chapter/designing-the-archive-for-directory-items/ )
Even if you do have to use a custom PHP template, we don't recommend making direct query calls from the Toolset tables like "toolset_connected_elements". Toolset offers Relationship API function "toolset_get_related_posts" to get the related posts:
https://toolset.com/documentation/customizing-sites-using-php/post-relationships-api/#toolset_get_related_posts
The downside of making direct queries from the database is that any future changes on the Toolset side will make your code ineffective.
Any posts which are shown correctly related to a post on the post edit screen mean that they are correctly joined in the backend. If you're seeing extra entries in the database, that could be the result of the incorrect import process or manual changes made to the database. You'll have to remove them manually from the database.
Also, there is nothing in the Toolset Types plugin that would automatically join posts in the relationship or revert the database changes. If you're experiencing that, it would be interesting to test the website's clone on a different server, to rule out the effect of server cache or optimization.
I hope this helps and please let me know if you need any further assistance around this.
Hey,
Thank you for your reply!
We will try to rewrite the code and see how it goes. Can we have this ticket open just in case it won't work?
Thanks for the update and I'll wait to hear back from you.
This ticket will stay open for the next couple of weeks. But even if you have a follow-up question after it is closed, you can start a new one and just share this ticket's link in it and we'll have the background information.