Skip Navigation

[Resolved] Display a default post Category Archive with a specific View template

This support ticket is created 6 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.

Sun Mon Tue Wed Thu Fri Sat
- 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10: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/Kolkata (GMT+05:30)

This topic contains 6 replies, has 2 voices.

Last updated by katerinaA 6 years, 10 months ago.

Assisted by: Minesh.

Author
Posts
#533900

I am trying to: display the posts of a specific Default Post Category, using a View template that I have created

#534093

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Hello. Thank you for contacting the Toolset support.

Could you please share more information about your issue. As I understand you want to display category archive - correct? if yes - what do you mean by default post category archive?

Few screenshots will be helpful to understand your issue.

#534102
2016_new.JPG
2016.JPG
posts.JPG

hi, thank you for replying.

I'll attach a screenshot, but I'm afraid my site is in greek, so it may look strange to you 🙂

I run an online magazine. Among many others, I have posted 20 posts (not custom posts, just plain WordPress posts).

These posts belong to a category called "2016". (pls see posts.jpg)
Please note that there are many more Categories (like "News", "Travel", "Tech" e.t.c)

If I click on my menu category "2016", I shall come up with a page that displays all these posts, but it uses my theme's template for Categories Archive. (pls see 2016.jpg)

I have already created a custom View and I would like to display all posts of category "2016" in this specific custom View, that I have created. If I make a Page and insert my custom View, everything looks fine (pls see 2016_new.jpg)
But if someone clicks on "2016", lets say from the site's breadcrumps, they will see the default archive template for "2016" (see again 2016.jpg)

So, what I'm looking for, is a way to assign a specific Custom View to just one of my Post's Categories and not affect the display of all other Post's Categories.

Maybe I've got something wrong. Maybe I should create a content template and assign it to a Taxonomy Archive... Well I did that as well, but I cannot see how I would be able to use my Content Template ONLY for "2016".

Hope all the above makes a bit more sense! Thank u

#534122

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

What if you try to filter your view by taxonomy by setting it as URL param?
=> https://toolset.com/documentation/user-guides/filtering-views-by-taxonomy/

And setup your breadcrumb links in such a way that you can pass the URL param as taxonomy slug?

#535457
2016_new.JPG
2016.JPG

hi, I think my problem is not illustrated clearly enough...
So, lets take it from the start!

I have Posts.
And I have Categories. One of them is called "2016" and has 10 Posts.

My theme uses a specific layout for showing the Posts of a Category. (again 2016.jpg)

Is it possible for my to Create a "Wordpress Archive" (2016_new.jpg) through Toolset and use it ONLY for Category "2016" and not for the general Taxonomy -> Categories?

#535474

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Well - when you create a taxonomy archive using toolset it will display the same taxonomy archive for all the taxonomy terms.

Better you create a template for your specific taxonomy archive like category-2016.php and add your customization there.

For example:

category-{slug}.php: 
For example, if the category's slug is named "news," WordPress would look for a file named category-news.php.

category-{ID}.php: For example, if the category's ID is "6", WordPress would look for a file named category-6.php.

More info:
=> https://developer.wordpress.org/themes/template-files-section/taxonomy-templates/

#535490

Excellent!
Thank you very much for the tip!

Have a nice day!

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