Custom Fields
Support Meta Box Builder Filter POST field items using other POST field

  • Creator
  • #4832
    Resolved Josué E. Pizano

    Hi! I have a problem with a MetaBoxes that using multiple POST type fields.

    I have 4 post types for the different structures existed in Mexican Law (Leyes, Títulos, Capítulos and Artículos). I have created a meta box for each one.

    In "Capítulos", for example, I have two Post fields (one for Leyes [to select the law on witch it depends] and other one for "Título" [to select the fraction of the law where this "Capítulo" is located]).

    The problem is generated because I need to filter to display only the "Títulos" that is registered under the law I selected on the prior field. The logical order for my user is:

    1. Select the law
    2. Select the title
    3. Select the chapter

    Note: I'm not using categories because this site require to create a lot of posts of each type and is really difficult for the end user to manage so many nested categories.


Viewing 2 replies - 1 through 2 (of 2 total)
  • Author
  • #4835
    Tan Nguyen

    Dear Josue,

    Please try Meta Box Conditional Logic:

    Then in your Post field, you can visible when post_type = Títulos

    Best regards,


    Josué E. Pizano

    Hi, Tan!

    I understood, but is not just showing or hiding the input, I need to filter the items available in the second field according to the previous post field. For example: There is many "Titulos" related to different Laws, but if my user selects the "Constitución Política" item, I need to show only those "Títulos" where there is that law selected... like an SQL join.


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