Skip Navigation

[Resolved] checking has_archive on already built post types

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

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Hong_Kong (GMT+08:00)

This topic contains 3 replies, has 2 voices.

Last updated by Luo Yang 4 years, 8 months ago.

Assisted by: Luo Yang.

Author
Posts
#1745671
Error.PNG
Toolset Error.PNG

Tell us what you are trying to do?
I am trying to check has_archive as there is an error. I believe this will fix my issue when building a page underneath the single php template.
Is there any documentation that you are following?
No
Is there a similar example that we can see?
Yes I have attached a correct page and the draft page with an error
What is the link to your site?
csgdocs.com

#1746121

Hello,

I assume those post types you mentioned in screenshot are created with Toolset Types plugin.
https://toolset.com/wp-content/uploads/2020/08/1745671-Toolset_Error.png
Please try these:
Dashboard-> Toolset-> Post Types, find and edit those post types:
in section "Options", enable option "has_archive", and test again.

More help:
https://developer.wordpress.org/reference/functions/register_post_type/#has_archive
Enables post type archives

#1748803

The picture is my issue. I am trying to make the post type page (breastfeeding medicine) similar to the others. How do I do that? I can not able to enable option "has_archive" due to duplicate slug names. How do I make the post have a picture and wrap like the other specialties?

#1753117

If you disable option "has_archive", that means your custom post type does not have a archive page, then you will not be able to setup the Toolset WordPress Archive.

In your case, I suggest you try to fix the "duplicate slug names" first, for example:
1) Find and change those duplicate slug names of post/page
2) Enable option "has_archive"
https://toolset.com/forums/topic/checking-has_archive-on-already-built-post-types/#post-1746121
3) Follow our document to customize the post type archive page to what you want:
https://toolset.com/course-lesson/creating-a-custom-archive-page/