I defined a custom field named crimedate using standard date format Y-m-d
. I defined the filters to make ordering by this date work in the post list of the backend, which works fine.
Now I need the possibility to show posts ordered by anniversary, using only day and month of the crimedate, but I don’t know how to do that:
Is it possible to sort dates only by day and month ignoring the year in hook pre_get_posts
? Or do I have to save days and month in two separte fields to make that work?
Xin chào các bạn và quý Thầy Cô. Hãy nhập từ khóa mình muốn vào ô tìm kiếm trên Website để tìm kiếm mọi thứ hoặc trên google các bạn hãy nhập từ khóa + dethihsg247.com để tìm kiếm các bài viết của chúng tôi nhé.
- Hiện tại chúng tôi có hơn 25 nghìn bài văn mẫu các thể loại.
- Kho tài liệu, đề thi học sinh giỏi các lớp vô cùng phong phú.
- Mỗi ngày cập nhật hơn 100 đề thi chất lượng từ các website bán tài liệu lớn.
Tải đề thi VIP với giá siêu rẻ tại Vip.Dethihsg247.Com