This is a question about the add-on 'CB Code Field'. It is not clear to me how I can design a good working Code Drop Down (Single Select). I am no expert in PHP code, but with some good examples I can make simple things. The dropdown function seems important to me, but I experience difficulties in writing the right code.
In have made a field called CB_kingetal where the user fills in a number between 0 and 261. In one of the interpretation the values 1, 21 or 41, 61, have the same outcome namely 'IMIX'. 2, 22, 42, etc. have the outcome 'IK'.
I want an automatic 'choice' in the Single Select Dropdown menu. The first value in the dropdown, namely IMIX, shoud be chosen automatically for users with CB_kingetal = 1, or 21 etc. From a logical point of view, the first value of the dropdown should become true if CB_field is 1 or 21, etc. What PHP code do I need to make this automation work?
I can't find good examples to find my own solution and need some clues.