Home › Forums › Pre-purchase Questions › Sorting values in custom fields › Reply To: Sorting values in custom fields
Hi there,
I think you can create 2 custom post types, Product and Supplier, and then create a number field for the price and post object field for the suppliers. You can set these two fields for the Product.
To get the highest and lowest prices, you can order the posts based on the custom field. This page should give you more idea about it: http://www.advancedcustomfields.com/resources/orde-posts-by-custom-fields/.
If you want to calculate a complex thing using these data, I think a custom table would be more appropriate.
Please try the free version first here: http://wordpress.org/plugins/advanced-custom-fields/.
I hope this helps.
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.