Okay
  Public Ticket #3782497
Post Loop Builder | Filter for Pages
Open

Comments

  •  2
    internet-ist-simpel started the conversation

    Hello, I try to filter pages inside the post loop builder. But it's not possible - not with Title or ID of the page. I get all pages returned, instead of just the pages I need.

    Is there a possibility to use a loop for chosen pages?

    Thank you.

    Attached files:  Bildschirmfoto 2024-12-12 um 16.29.21.png

  •  1,923
    Judith replied

    Hi there,

    Thanks for writing to us.

    To filter the pages you need a taxonomy like a tag or category, since pages don't have those you may not be able to filter.

    I hope this provides clarity.

    If you have any more questions or run into any problems, please feel free to reach out.

    Best regards,

  •  2
    internet-ist-simpel replied

    I do of course understand that, pages don't have categories and taxonomies.

    But how should I create a grid with three columns, which will link to three chosen pages? Especially in the beautiful design of the post loop.


    Is there another way to do this?

  •  1,923
    Judith replied

    Hi there,

    Thanks for writing back.

    With pages at the moment we don't have any other way, You may need to display them all, however from the Post Loop Builder you can use settings such as this to adjust the structure, we also have an option to sort and even limit the number of pages you want displayed on the grid:

    6031644978.png

    I hope this proves helpful for you. If you have any more questions or run into any problems, please feel free to reach out.

    Best regards,

  •  8,940
    Tahir replied

    Hey Again,

    You can use this plugin https://www.wpbeginner.com/plugins/how-to-add-categories-and-tags-for-wordpress-pages/ to add tags/categories to pages and then use them in the Post Loop Builder.

    Best 


    ThemeNectar Support Team 

  •  2
    internet-ist-simpel replied

    Hi Thair,

    thank you for the solution. If some else does need just Code for integration. It is simple:

    https://stackoverflow.com/questions/14323582/wordpress-how-to-add-categories-and-tags-on-pages

    Just add to functions.php in your theme (child-theme-)folder:

    function myplugin_settings() {      // Add tag metabox to page    register_taxonomy_for_object_type('post_tag', 'page');     // Add category metabox to page    register_taxonomy_for_object_type('category', 'page');  } // Add to the admin_init hook of your theme functions.php file add_action( 'init', 'myplugin_settings' );
  •  3,001
    Andrew replied

    Hi again,

    Thank you for getting back to us.

    I'm glad we could assist and thank you for the code you suggested.

    Feel free to open another ticket if you have any other queries.

    Cheers,