Skip Navigation

[Resolved] CPT Navigation – Expandable/ Collapsible Sidebar Widget Navigation

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

No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.

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 peterG-9 8 years ago.

Assisted by: Luo Yang.

Author
Posts
#380020

I've used Types to create a CPT (for a Charitable Trust website) that is named as "Contributors" with an associated Custom Taxonomy. Contributors have Patrons, Trustees, Foundation Friends, Consultant Advisors, etc as child categories and taxonomies.

50 + Contributor posts have been created under the various subcategories and assigned the relevant sub taxonomy and the page template has been set to Side Navigation under the Avada Theme Framework.

I have created content templates for the single post items and created the same or the desired archive pages for each subcategory using Views. So I now have 50+ CPT posts and 5 CPT archive pages

    all set to side navigation

to keep the section navigation contextual to that section.

Now comes my problem. I need to have an expandable/collapsible sidebar navigation menu that is contained to within the Contributors categories that displays at the top of the sidebar allowing for other content widgets to display underneath it.

I've done the research and tried the plugins; I've put in custom CSS and JS in the Avada child theme, but, to be honest not gone the route of dumping tons of experimental code into functions.php.

I just need to navigate efficiently within the Contributor's section without having to use the native WP Custom Menu which displays everything as expanded. Is there a way to do this with Views? Or anything?

The issue is fundamental to the continued development of the site. If we can get this right, the rest falls into place and ones' sleep might become somewhat more restful. I'd appreciate any help or advice that you may be able to provide.

Thanks

PeterG

#380080

Dear PeterG,

I suggest you try with the Nested View + JqueryUI Accordion.
1) Create a nested view,
a) parent view list top terms of Custom Taxonomy "Contributors"
b) Child view list posts of term from parent view.
More help:
Views Inside Views – Display Nested Multidimensional Lists
https://toolset.com/documentation/user-guides/using-a-child-view-in-a-taxonomy-view-layout/

2) use JqueryUI Accordion to do the Expandable/ Collapsible
hidden link

3) put the parent view into your widget.

#381344

Spent a day messing about with your suggestion without much luck. I could only get Contributors to display the child archive pages (Patrons, Trustees, etc.) as links. Rather than being able to have a sidebar menu structure that looks like:

Our Contributors
> Foundation Patrons (CPT Archive page - in a collapsible accordion)
> Single Patron 1 (Title with Link)
> Single Patron 2 (Title with Link)
> Single Patron 3 (Title with Link)
> Foundation Trustees (CPT Archive page - in a collapsible accordion)
> Single Trustee 1 (Title with Link)
> Single Trustee 2 (Title with Link)
> Single Trustee 3 (Title with Link)

Of course, just using the native WP sidebar navigation, this is achieved, but it's all expanded. So I'm just using a third party auto CPT menu plugin at the moment.

Ah well ... perhaps a flash of brilliance will present itself in due course.

#381422

Since it needs custom codes, could you duplicate same problem in a test site, and fill below private detail box with login details and ftp access, also point out the problem page URL and View URL, I can try setup a demo for you

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