Answer the question
In order to leave comments, you need to log in
Inferring authors from their posts in WordPress + ACF?
Given :
There are authors made through Custom Post Type
There are articles where the Custom Field specifies the author through the record object from the list
There is archive-authors Output of all authors in the list
Question. How to filter authors based on the novelty of the article in which they are listed.
Example
Yes Author #1. Author #2, Author #3, Author #4
Author #4 wrote the article yesterday,
Author #2 Wrote the article the day before yesterday
Author #1 wrote the article a year ago
Author #3 Wrote the article today
I.e. their output on the page should be Author #3, Author No. 4, Author No. 2, Author No. 1
Please help with the logic, what data should be appealed to in order to get their sequence.
Answer the question
In order to leave comments, you need to log in
Read about autoload
include_once "../models/User.php";
this is a collective farm, which should not work like this.
If I understood the logic of the organization correctly, then I would simply request the created records by the time they were created, but I would display not their name, but this line, where the variables are the data about the author from custom fields, and the time indication is through a function that will display it in this form (it is easily searched on the Internet).
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question