Home › Forums › Feedback › Сustom pagination in the custom field › Reply To: Сustom pagination in the custom field
Hey,
I really didn’t get the question, but rather than filtering it in the query, you can use this.
$posts = get_posts(array(
'post_type' => 'letters',
'numberposts' => -1,
));
foreach($posts as $post)
{
if(get_field('letter_sent', $post->ID) == '2019')
{
//your code
}
}
Also the meta_key is not same when acf saves it. Try enabling the Custom fields option in the Screen options. You will get the idea how acf saves the custom fields.
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Privacy Policy. If you continue to use this site, you consent to our use of cookies.