Home › Forums › General Issues › Number field that can be unlimited › Reply To: Number field that can be unlimited
A number field.
Assuming that you have a range of 1 to 9999 before unlimited and you want unlimited to be sorted as highest then you would represent unlimited with 10000.
At least that’s the way I’d do it.
Or if I was going to make it easy for the client I would have a radio field to select “unlimited” or “set limit” and then a number field to allow setting the limit with a max value. This number field would be conditional based on the radio field. Then I would create an acf/save_post action that would set this number field to 10000 if the radio field was set to unlimited making unseen by the user.
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.