Skip Navigation

[Resolved] Best practice for archives

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

This topic contains 2 replies, has 2 voices.

Last updated by markH-16 2 years, 9 months ago.

Author
Posts
#2295545

I have a cpt called 'documents' with two taxonomies, 'letters' and 'reports'. I will only be displaying them through Views according to their taxonomy; one for 'letters' and one for 'reports'. It would never be useful to display both the letters and reports in the same archive. But, I'm wondering if I should create a WordPress archive for 'documents' anyway, just so I have the proper WP structure. I'm assuming I can't create a WP archive for a taxonomy.

#2295649

Nigel
Supporter

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

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

Hi Mark

Without customising anything with Toolset, by default you will have a post archive for your documents CPT, where all document posts are listed, at a URL of site.com/documents/.

You will also have taxonomy archives for both letters and reports. The name "taxonomy archive" can be confusing, because it lists posts, posts that have the term of the taxonomy in the url assigned to them.

I don't know what the terms of letters or reports are, let's say "alpha", "beta", and "gamma", and "one", "two", and "three" respectively.

So at the url site.com/letters/alpha/ it will list all posts that have the term alpha of the taxonomy letters assigned to them.

At the url site.com/reports/two/ it will list all posts with the term two of the taxonomy reports assigned to them.

(I'm using documents, letters, and reports, but maybe the slugs are actually document, letter, and report.)

So, unless your settings for the post type and taxonomies disable archives, then those archives exist already (and will be output according to your theme template files).

With Toolset you can then customise them (at Toolset > WordPress Archives), both the appearance, but you could also add filters or change the order to order by post title rather than date, for example.

#2295749

Thanks Nigel. I didn't quite understand that archives are listed and displayed the way you explained. Now I've got it!