enter image description hereI have a content type, I'm trying to add a field that's a boolean. I want the options to be yes or no. This is something I thought would be relatively simple however, I keep getting an error message. I've attached 2 screenshots. 1 is the configuration for my boolean. The other is the error message my site gets. Can someone help me. What am I doing wrong?

enter image description here


The Boolean field accept only 0 and 1 as value.
if you want to add allowed values by PHP Code should be:


I create a Boolean field on Content type and i set the On value to Yes and
off Value to No.
As you see In the below screenshot the value of input is 0 for NO and 1 for Yes. enter image description here

  • I followed your screenshot and did it exactly how you did. I'm still getting an error message it says "ParseError: syntax error, unexpected '1' (T_LNUMBER) in cck_allowed_values_php() (line 2 "
    – Aishah91
    Nov 15 '18 at 14:01

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.