Expandable tree structure for categories select?

This topic contains 5 replies, has 3 voices, and was last updated by  Kiran 5 years ago.

We have moved to a support ticketing system and our forums are now closed.

Open Support Ticket
  • Author
    Posts
  • #480401

    John Els
    Expired Member
    Post count: 65

    Hi,

    A site I’m working on has about 900 categories in a 3-tier structure. We have Main Categories, with Sub Categories under that, and Sub-sub Categories under that.

    I’m using the Checkbox setting to define the box where the user will be selecting categories on the listing edit page. As you can imagine, 900 categories makes for a daunting list of categories to select from.

    Is it possible to continue to use the Checkbox setting (that works well), but show the categories in an expandable tree structure? The idea is to first show only Main Categories that the user can expand to show Sub Categories and then Sub-sub Categories.

    Thanks!

    John

    #480421

    Alex Rollin
    Moderator
    Post count: 27815

    Hello,

    Select2 doesn’t support this by default, but you could look into customizing the display with something like this: https://github.com/clivezhg/select2-to-tree

    You can find developer support for customizations here: https://geodirectoryexperts.com/

    I will flag your topic for the developers and they will let us know if there is another workaround that we can help with.

    #480866

    John Els
    Expired Member
    Post count: 65

    Thanks so much, Alex. I will look into Select2.

    I think it would be a useful thing to implement this as an option in GD. When a directory has as many categories as this site I’m working on, it can become an intimidating thing for users to select categories. A tree-like checkbox option will make it a lot easier for them.

    John

    #481088

    Kiran
    Moderator
    Post count: 7069

    Hello John,

    Currently there is no easy way to achieve what you asking.

    We recommend you to split main categories into different CPT.
    Suppose there is a one CPT(gd_xyz) with two categories Hotels & Restaurants then it can be split in gd_hotel for Hotels & gd_restaurant & Restaurants .

    Regards,
    Kiran

    #481131

    John Els
    Expired Member
    Post count: 65

    Hello Kiran,

    Thanks for that suggestion.

    I ended up using CSS to achieve something close to what I was looking for, i.e. making it visually easier for people to select from a large amount of categories. I made the tier 1 categories bold and with larger text, tier 2 (the important tier) I made blue with a light gray background, and tier 3 is just regular text. I also increased indents between tiers. This achieved some visual separation when scrolling down the list, making it easier for users. I have attached an image to illustrate.

    Thanks for your help!

    Regards,
    John

    #481334

    Kiran
    Moderator
    Post count: 7069
    This reply has been marked as private.
Viewing 6 posts - 1 through 6 (of 6 total)

We have moved to a support ticketing system and our forums are now closed.

Open Support Ticket