You just need to put a query in your template. As an example, I use less conditions.
You may add what is necessary later.
// prepare arguments
$args = array(
'post_type' => 'members',
'orderby' => 'name',
'order' => 'ASC',
'post_status' => 'publish',
);
// create a query based on arguments
$query = new WP_Query($args);
while ($query->have_posts()):
$query->the_post();
// output here
// WP builtin: eg. echo get_the_title();
// you can add html table here
// ACF builtin: echo acf_get_metadata( get_the_ID(), 'meta_name' )
endwhile;
wp_reset_query();
In between the while loop
, you can create html table. I suppose you know how to create html and add php code so I just give you the essential idea.
For query, you may refer to WP_Query class
Related Posts:
- Meta Query “IN” doesn’t work with ACF checkbox filter
- List events by month
- Clean URL permalink for custom post type
- Custom post type loops with different page templates
- Custom Post Type .current-menu-item not applying on Custom Post Type Archive Page
- Show ACF field from custom taxonomy and display on the single template
- Change message given when deleting post from custom post type
- is_page_template not working as expected
- Link users to a custom post type
- Custom Post Type Taxonomies -Posts not showing in Category or Tag pages
- Using wordpress template tags within an array
- How to display Custom Post Type Post based on Tag with Shortcode Parameter?
- get_posts of Custom Post Type AND Custom Taxonomy
- WP_Query to select custom post type with Advanced Custom Fields (ACF) date
- How to update post meta on uploaded image from a custom form?
- Displaying custom field according to date
- Create short URL with auto 301 redirect
- Query entries from custom post type in an ACF flexible content field
- How to use single.php for creating, reading and editing Custom Posts with ACF
- meta query not retrieving posts
- Template code to split a post and print a custom field?
- Fetch data from two custom post types and create multidimensional array for output to html table
- Custom front-end form for adding post – Category problem
- count & sum the value of custom field of the author post in dynamic posts
- Grouping custom wordpress post types by acf value
- WordPress – display relationship between blog posts and custom posts
- Custom sorting in post columns by ACF Pro Select Field
- Accessing download link from the loop with WP Download Manager Pro
- Custom post type option page template
- CPT: execute code after load if parameter is set
- ACF Post Content Not Being Searched
- Values show up in custom home page but not in custom post pages
- Display related post content and custom field content
- Group/list/sort custom post type posts by date in tabs from acf datepicker field
- How to make a custom search template for custom taxonomy?
- Can’t pick up a field created with Advanced Custom Fields
- Why isn’t my custom post type using the corresponding custom post template?
- Custom post tag images not displaying with ACF
- Get month and day from a Date Picker custom field
- using ACF datepicker to filter posts on a page
- Custom Post-type not returning the right child_of
- PHP Button Custom link [closed]
- Getting ACF relationship field information
- using a template for more then 1 page
- How to I add count of custom posts listed in a post as a prefix to its title
- Custom post type is_singular condtional not working when managing sidebar display
- How can I remove the “Add New” button in my custom post type?
- Taxonomy, Terms, and Template Files
- Filter a custom field based on selection of another custom field (ACF) [closed]
- Categories under custom post types doesn’t show properly
- Custom templates for posts like for pages: page-{id} vs single-{id}
- Trying to manage templates on a blog with lots of custom taxonomies
- How to get current post id of a custom post type in a loop using template singel-{custom type}.php?
- Pagination Issue: Custom Post Type In Index
- Order WordPress Custom Taxonomy Pages & Pagination Not Working
- Rewrite WordPress URL to show CPT meta field data
- What’s the difference between same wp functions get_posts(); functions in different form?
- how to check if custom post type column already exists?
- Can I list a custom post type within another custom post type in the admin area?
- How to display custom WP menus?
- A case for Hierarchical Custom Posts
- Custom Post Types vs. Advanced Custom Fields (with Repeater Field add-on)
- Custom post type pages return 404 page?
- How can I group posts by months and years?
- Saving fields in a drop-down in WordPress
- I need to add a filter to prepend the term ‘National – ‘ to the post title if the post is tagged to multiple states
- set_query_params using custom params defined in functions file?
- WordPress: Custom User Role cannot access Custom Post Type | “Sorry, you are not allowed to access this page”
- How to define the template for custom posts?
- How to export custom post type with ACF to individual file with automation?
- Accessing a protected property of a post
- Compare Two Custom Post Types Using The Same Custom Taxonomy
- List of a specific Custom Post Type in Custom Template
- Require custom post type if is_admin() – template doesn’t show up?
- Custom field with Types: get custom field’s value label (of type select)
- WordPress sitemap with Custom Post Types
- How can I sort the order of multiple custom field values in a custom post type?
- php dynamic content inside shortcode
- I want to rewrite the URL of a specific post with a specific custom field to easily analyze in Google Analytics
- Create if else for post types in WP_Query ‘post__in’ values
- CPT email notification including only new value custom fields
- custom post template design with dropdown option
- Post Attribute Section missing for Custom post type
- ACF meta_key and meta_value break loop
- search results to show individual ACF fields from inside custom posts
- Disable Sidebar on certain pages
- Videos Post Type with Custom Filters
- Use output of wp_dropdown_categories($args)
- Organising custom taxonomies and custom post types
- How to load custom post type plugin after acf options page (or get settings from there another way)?
- can’t see categories in appearance-menu-categories
- Parent to another Custom Post Type – Template files not being recognized
- How to avoid hardcoded text in a custom page template?
- WordPress custom field images not getting inserted into array
- Meta-Box to add multiple items one at a time and on publish save all
- Values inside a custom field to determine which category posts to display
- Problem retrieving custom field for a custom post type
- Only One Post of Custom Post Type Appearing on Template Page
- Retrieve a post with its ACF repeater fields in wordpress
- Two custom post type relations