Home › Forums › General Issues › Trying to ORDER foreach loop by ACF field › Reply To: Trying to ORDER foreach loop by ACF field
What would you suggest then? To clarify.
I have a CPT “Termek”
This CPT has a Category (also called / sorry for the confusion) of “Termek” which has 5 children
– Termek 1
– Termek 2
– Termek 3
– Termek 4
– Termek 5
I would like to order these based on the $number field so that if say “Termek 5” has an ACF field of $number with the value of 3, it will show up third in the foreach statement. Am I going about this in the wrong way?
Thanks!
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.