Use custom fields wp_query
Ex
<?php
$args = array(
'post_type' => 'page',
'meta_query' => array(
array(
'key' => 'mytitle',
'value' => 'title',
'orderby' => 'mytitle',
'order' => 'DESC'
),
)
);
$query = new WP_Query( $args );
if ( have_posts() ) while ( $wp_query->have_posts() ) : $wp_query->the_post(); ?>
<tr>
<td><?php echo the_field('educational_ranking'); ?></td>
<td><a href="https://wordpress.stackexchange.com/questions/60150/<?php the_permalink(); ?>"><?php the_title(); ?></a></td>
<td><?php echo the_field('current_students'); ?></td>
<td>£<?php echo the_field('tuition_fees'); ?></td>
<td></td>
</tr>
<?php endwhile; rewind_posts(); ?>
Related Posts:
- Sort query_posts for Parent Pages to menue order or the count?
- change the default order of posts only for specific categories
- Remove Post if Advanced Custom Field is checked to fix paging
- WordPress sorting posts by date and title using a dropdown
- Display all values of custom a field created with ACF on a page
- Build a content and excerpt grid loop with paging and options for # of posts
- Display sorting options dropdown when using WooCommerce product category shortcode
- Inserting Gravity Form checkbox values into Advanced Custom Fields [closed]
- Alter query on edit.php
- Conditionally loading JavaScript based on the Advanced Custom Fields in the post
- If Custom Field is empty don’t display div
- Drop down+sort blog posts date added/most popular
- What is the most efficient way to search users by their display name?
- How to order posts by modified date without using ‘query_posts’?
- Archive listing of posts by publish year (multiple years)
- Is there a reason why my wordpress PHP page isn’t loading into my PHP template
- Getting movie and serial on actor page
- Conditional statement for parent, child and grandchild pages
- The values of custom fields are not available functions.php
- Two posts in same div – WP loop
- how to display active, upcoming and past event with featured listing with pagination
- Problem with ACF shortcode with Repeater Field in WordPress? [closed]
- Unique key for each row in a repeater field
- How to Explode a Textarea Field and Echo each line separately, wrapped with HTML
- Advanced Custom Fields Image Field returning ID instead of URL [closed]
- Sortable admin column for one meta key with three possible meta values
- Include a specific post to the query_posts and remove it if it is already in the returned list
- Can an array be used as a meta_query value?
- Insert all post IDs in new database table
- list posts and wrap them alphabetically A-Z
- ACF check if variable has http, if else return string
- Exclude posts from homepage having a specified tag
- Advanced Custom Fields: Post Object – Not returning data [closed]
- Looking for most performant way to execute several similar WP queries within shortcodes
- ACF: Only get first row of a Repeater Field
- Order posts randomly, not by date
- Working with query_posts ( arrays and query strings)
- Trouble With Conditional Logic in PHP
- Can’t search posts using WP_QUERY inside AJAX Function
- Importing hard coded custom field into acf field
- Strip characters, Including spaces, for tel: link
- How can I add multiple ‘tax_query’ arrays via a loop?
- ACF page while loop breaks footer while loop
- Change output based on text field value
- Nesting if statements to echo only one string based on what tag was filtered?
- Displaying the last post on static homepage
- Using Advanced Custom Fields to create a per page slider
- Sort posts by custom fields value using dropdown menu
- Display PHP within HTML values
- Using loop pagination on single.php
- How to Sort posts by Vote Count?
- Logged in user ID as post ID
- How to sort posts based on the value (number) of a post’s metadata?
- ACF: how do I get the fields and its values of a specific group?
- Why do WP_Query results change after updating unrelated Advanced Custom Fields (ACF)?
- Sort custom meta column by other meta value
- Saving an array of dynamic repeater data as post_meta
- Sort the result of the main Query in shop page by a custom taxonomy
- WP_Query adds “(wp_posts.ID = ‘0’)” so no results are returned
- Output ACF repeater on frontend user’s profile page (created with Ultimate Member) [closed]
- Remove the first 5 characters of the_title and orderby that
- Unread Repeater field IMG alt not working
- Unable to write multiple values back to ACF user field – PHP
- Update grandchild repeater field with value per row
- How to use thumbnail size of image if I’m only using src to get image
- Slick + PHP + ACF + JQuery slide reveal not working
- Advanced Custom Fields – display label and value only if value entered
- Advanced Custom Fields not displaying
- How to list posts from a plugin taxonomy?
- Counting Search results, and displaying the offset per page
- Download PDF after CF7 form submission
- How to get post ID in a Page?
- How to create an ACF shortcode with Repeater Field in WordPress? [duplicate]
- Pagination broken on is_front_page()
- How to keep track of when a vote is cast?
- Upload non-featured image to image field
- HTML Special Characters in URL string [closed]
- ACF put a comma after the last repeater field value [closed]
- Show ACF field with link to ultimate member profile/WordPress user profile below the post (single post layout)
- Form search query – displaying ACF “Post Object” field as results
- InnerBlocks with allowedBlocks not working with acf_register_block
- Accessing values from ACF sub field (flexible content area) in PHP
- Creating an image from a custom field
- Can I set up a hover animation in CSS depending on a PHP conditional?
- Get ACF options field in PHP acting as CSS
- ACF & Bootstrap Gallery Shows Blank Slides [closed]
- Conditional multidimensional arrays and array_map
- ACF Repeater Pagination stopped working since upgrade to php7.2
- How can I count ACF sub_field with a certain value
- what is the method to echo class attribute inside the i tag? [closed]
- Order BY Most Liked And Published Between Previous Week Monday And Next Week Monday
- Refactoring long if/else php chains
- Getting taxonomy category Image from ACF [closed]
- Problem with adding custom CSS class to image in ACF Photo Gallery plugin [closed]
- Posts are not looping through correctly
- How to tag the main tag? [closed]
- Show get_sub_field value if it exists [closed]
- Update post meta – Custom field does not match meta-key
- Removing custom sort order from admin page listing
- Advanced Custom Fields [closed]