Skip to main content

All Questions

Tagged with
1 vote
0 answers
419 views

Compare ACF date field (if exists) and post date and order DESC

I have an ACF date field (same format as post date) and in my Query I want it to be compared to the publish date of the post: If erstelldatum is not empty use erstelldatum for order If erstelldatum ...
Omitheus's user avatar
0 votes
2 answers
260 views

Posts sortable column not sorting properly for custom field numbers

I have a custom field for view counts that are stored as numbers. I added a Views column, and made it sortable, but they are not sorting properly. The results when I click on the Views column are ...
Michael's user avatar
  • 281
0 votes
1 answer
980 views

Sort categories by custom field in WordPress admin

I know there are a lot of threads about similar issues, but I can't figure out why my custom sort won't work in the category admin page. Here is my code to add the ACF field as a column to the ...
Meghan Prestemon's user avatar
1 vote
0 answers
153 views

WP_Query order by custom field, then randomly order some of results

I'm not entirely sure how to word my question, but I'll give it a go. Basically, what I'm wanting to do is order a group of posts by a custom field. I have a True/False custom field, created using the ...
Timothy Davis's user avatar
0 votes
1 answer
266 views

Sort custom post type by most current date picker

I'm trying to sort custom post type made with ACF plugin by most current date. Ideally future most current post should be first. Currently, I'm sorting by date, which gives me the earliest post as the ...
ivan marchenko's user avatar
1 vote
1 answer
119 views

Advanced search by two criteria - sort by location and date (ascending or descending)

I have spent a couple of days working on this and I am still not able to figure it out. I am trying to make advanced search filter that sorts posts from a specific category on two criteria: location (...
Badan's user avatar
  • 225
1 vote
0 answers
96 views

Store CPT 'Reviews' average ratings to a WordPress DB table or to a DB custom table?

I am working on this portal in which users can review the services (with description and rating) of a cultural place. BASICALLY, I created two Custom Post Types (CPT) with Pods, one is ...
sohlweber's user avatar
0 votes
1 answer
1k views

How to Sort by Date When Using d-m-Y Format

This question is pursuant to the following - How to Sort Custom Field Admin Column by Date I'm attempting to add functionality to sort a custom post admin list column by a date manually specified in ...
Connor's user avatar
  • 3
0 votes
2 answers
4k views

How to Sort Custom Field Admin Column by Date

I have a WordPress website with a custom post type called 'Courses'. On the WordPress dashboard page listing each course I've added a new column displaying a custom field, which is a date, called '...
Connor's user avatar
  • 3
2 votes
1 answer
394 views

Sort by two dates. Default entry date and custom field if present

I have a custom post type where there is an option to sort by date. There is however a custom date field that allows changing the display date. This custom date field is not always filled. Right now ...
Chris's user avatar
  • 125
1 vote
0 answers
713 views

WordPress Comments sort by custom meta key

I want to sort comments by a number of likes which is saved as a meta_key in the wp_commentmeta table: I have tried two ways but it doesn't sort the comments by most liked comment at the top. Please ...
Emma B's user avatar
  • 21
1 vote
0 answers
199 views

Understanding the orderby in WP_Query?

For quite a while I have been trying to query posts, with 2 different meta_queries, and order them differently. I followed the WP codex. Recently I have found out that I have been mistaken this ...
RobbTe's user avatar
  • 242
0 votes
0 answers
85 views

Order 2 meta_queries differently in WP_Query?

I have a custom WP_Query with 2 different meta queries. I want to order the results of both queries differently. The first meta_query I want to order by a custom field (high integer - low integer). ...
RobbTe's user avatar
  • 242
0 votes
0 answers
494 views

Sort posts on custom field AND after that sort on date?

I'm having trouble to understand customizing the new WP_query. I've found the script below, partly, here in order to get the sticky posts. I've further edited it in order to: first get the (sticky) ...
RobbTe's user avatar
  • 242
0 votes
1 answer
587 views

change order of images attached to post

Im not quite sure how to explain my issue so let me know if Im unclear about anything. I have on my front-end post form a multiple file upload input that uploads files to my specified folder and ...
730wavy's user avatar
  • 193

15 30 50 per page
1
2 3 4 5