Questions About Portfolio Page Templates and Index Pages

I have several questions regarding portfolios.

To start, I need to make a portfolio with sorting options. For the most part, not too difficult to do.

Going the route of portfolio page templates, I set up an archive and create a layout but some issues arise.

  • Portfolio title cannot be changed. It’s set to the default “Portfolio”. Clicking Settings on the layout and changing the title under General does nothing
  • While you do not need a looper provider for Archives, you can’t sort portfolio items (default is to sort by publish date)
  • If you use a looper provider, pagination stops working

So okay, this doesn’t 100% work. What about index pages then? This feels more difficult as you cannot use Cornerstone for customization and are left with a handful of options in Wordpress for setting columns. While yes, I can now change the Portfolio title to whatever the page title is, it doesn’t help that I cannot customize the page without digging out a CSS reference to make customizations.

Also, it’s not clear how to actually make the portfolio sorting option visible. I know there’s apparently some issues with it right now according to some previous forum posts but it’s not even clear how to access this feature other than the toggle under Portfolio Options.

In short, neither method satisfies what I need to do, though portfolio page templates are closer. Any advice would be appreciated. If I’m somehow just misunderstanding how portfolios work in X theme then I apologize. Just point me in the right direction and I’ll be on my way.

Hey @dobacco,

Actually, you can use pagination even if you use the Looper Provider in an Archive Layout. So with that said, using the Layout Builder would be the right choice as you both can create a filter and the pagination will work.

You can create filters like shown in the following user tutorial video:

Regarding your problems:

I wonder why this is a problem. You really can’t change the portfolio or page title but, if you’re in the Layout Builder, you have a choice to display a static text so displaying the “real” title, isn’t necessary. Please detail what your exact setup is so we’ll know this is a problem. Screenshots would be helpful.

Since I’ve mentioned you can use a Looper Provider, you can filter posts in the Query String like shown in the screenshot below.

image

Not if you include the paged parameter and get the page number from the URL by this Dynamic Content {{dc:url:segment fallback="1" index="3"}}.

image

Below is the sample Query String in my test site in case you want to test it out.

orderby=date&order=ASC&category_name={{dc:term:name}}&paged={{dc:url:segment fallback="1" index="3"}}

It is important to note though that you should not output the category slug in the URL. Otherwise, the category_name would get mixed up. Multiple category names would be a different setup and we’ll not discuss that in this thread to avoid confusion.

Try setting those suggestions up and we’ll continue in case you get stuck.

Thanks.

Christian,

Thank you for the quick response.

So I’m a bit stuck. the Query String you provided just filters blog posts so I made it more specific to our needs:
orderby=date&order=DESC&post_type=x-portfolio&category_name="Upcoming Releases"&paged={{dc:url:segment fallback="1" index="3"}}

While it worked with just post_type=x-portfolio, I wasn’t sure how to target a specific portfolio category as we have multiple ones and I needed to focus on only one category. For the sake of testing, I removed category_name and tried testing pagination but nothing happens still.

As for the portfolio title, I’m not entirely sure what else I can show but yeah, changing the title in General doesn’t do anything.
image

I also tried testing the filter customization as suggested in the above video. While the text list generated does get ordered accordingly, the actual portfolio items are not affected.

Again, I’m likely missing something so any guidance on my situation is appreciated.

Hi @dobacco,

You need to use the category slug instead of the category name you are using in the Query String. Your Query String probably looks like the following.

orderby=date&order=DESC&post_type=x-portfolio&category_name=upcoming-releases&paged=

Hope it helps.
Thanks

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.