Home Forums Backend Issues (wp-admin) Page Link > Filter by post Format > miss "Standard" one Reply To: Page Link > Filter by post Format > miss "Standard" one

  • Hi @jonas

    I see the problem now. It seems that the post format will only show up in the list if you have a post set to that format. That was why I couldn’t find it.

    Unfortunately, there’s no “standard” format in WordPress. Instead, please try the following code:

    function my_page_link_query( $args, $field, $post_id ) {
        // only show children of the current post being edited
        $args['tax_query'] = array( array(
                'taxonomy' => 'post_format',
                'field' => 'slug',
                'terms' => array('post-format-aside', 'post-format-gallery', 'post-format-link', 'post-format-image', 'post-format-quote', 'post-format-status', 'post-format-audio', 'post-format-chat', 'post-format-video'),
                'operator' => 'NOT IN'
        ) );
        // return
        return $args;
    // filter for a specific field based on it's name
    add_filter('acf/fields/page_link/query/name=page_link_field_name', 'my_page_link_query', 10, 3);

    That code will modify the page link query and get all the posts that don’t have any post format.

    This page should give you more idea about it:

    I hope this helps 🙂