Show Custom Field By Category (and sub categories)

Support MB Builder Show Custom Field By Category (and sub categories)Resolved

Viewing 12 posts - 1 through 12 (of 12 total)
  • Author
    Posts
  • #19566
    SteveCoSteveCo
    Participant

    I am trying to figure out how to display custom fields by parent and any of its subcategories from the GUI (I have the AIO license). If I choose "Taxonomy" from the Settings tab in Custom Fields, I don't see the category/categories I am needing.

    #19578
    Long NguyenLong Nguyen
    Moderator

    Hi Steve,

    The Settings tab supports to display the field for taxonomy. The default taxonomies of WordPress are Category, Tag, and the category name or sub-categories is the term of the taxonomy Category.

    For more information, please follow the documentation
    https://developer.wordpress.org/themes/basics/categories-tags-custom-taxonomies/
    https://docs.metabox.io/extensions/mb-term-meta/#creating-meta-boxes

    I hope that makes sense.

    #19671
    SteveCoSteveCo
    Participant

    I am not sure if I follow... So they CAN display in a parent/child relationship in the builder? I don't see anything in the, "Settings" for this. I am wanting to see that visual representation of parents and children (Category/Sub Categories).

    #19672
    SteveCoSteveCo
    Participant

    I have a category called, "Toys" and a subcategory called, "Action Figures" and another subcategory called, "Star Wars" and "TRANSFORMERS". When I go to Settings > Taxonomies, I would expect to see the categories listed as:

    Toys
    - Action Figures
    -- Star Wars
    -- TRANSFORMERS

    But I don't see this.

    #19673
    SteveCoSteveCo
    Participant

    See attachment. I have 3 "Category" Taxonomies and I have no idea how to distinguish between them. See screenshot (you can only see 2 of them in the screenshot). Also, I have subcategories under my "Category" taxonomy but since they do not appear, I cannot target them. See attachment.

    https://nimb.ws/jzixTd

    #19677
    Long NguyenLong Nguyen
    Moderator

    Hi Steve,

    Let me explain more about this case. There are some custom posts type have the same taxonomy name Category but have different slug, please see my screenshot https://share.getcloudapp.com/RBuv2NxG

    Toys -> is the term of the taxonomy
    – Action Figures -> is the child term of Toys

    So if you show the field for taxonomy, it will display on all the term's setting page of the taxonomy. You can also take a look at my short screen record.
    https://www.loom.com/share/3bad103f2bc3417580373491f513abcc

    #19680
    SteveCoSteveCo
    Participant

    Thanks. I believe I understand how it's working now. However, I still think it would be helpful if there was a way to distinguish between the taxonomies; just as you identified them via the screenshot. Also, I don't show the "Select Advanced Field" options on my category term page but rather all of the custom fields that I set within the "Settings" tab with the "Category" taxonomy.

    #19691
    SteveCoSteveCo
    Participant

    After re-watching I still don't see a way to target a specific category "term" (subcategory). Am I missing something?

    #19692
    SteveCoSteveCo
    Participant

    I just realized I posted in the wrong categories with several posts. Feel free to move them accordingly and delete this post.

    #19704
    Long NguyenLong Nguyen
    Moderator

    Hi,

    I've moved it to the MB Builder sub-forum, we can discuss more on this topic.

    Currently, the extension MB Term Meta only supports to show the field on all terms of the taxonomy. I will create a feature request to support showing the field on specific terms, just like 'terms' => array( termID, or termSlug ).

    #19709
    SteveCoSteveCo
    Participant

    Thank you!

    #19822
    SteveCoSteveCo
    Participant

    This is my suggestion to display the terms within a taxonomy:

    Toys
    – Action Figures (id#)
    — Star Wars (id#)
    — TRANSFORMERS (id#)

Viewing 12 posts - 1 through 12 (of 12 total)
  • You must be logged in to reply to this topic.