Home Forums Bug Reports Save 'other' values to the field's choices broken


Save 'other' values to the field's choices broken

  • Hi,

    Since the last update ( ACF pro 5.5.14 ) i’m experiencing problems with the checkbox field. I have a checkbox field for my CPT ‘news’ with the following options selected:

    – Allow custom : yes
    – Save custom : yes

    When I save a post (news) , the complete checkbox field gets deleted. It doesn’t show up in the post options, and also it is completely deleted in the field group.
    This only happens when the option ‘save custom’ is selected.

    Another weird thing: the (custom) checkbox options that I created before I tried to save the post, are shown up in the post list (backend) as being posts :-S

    Hope you can help me out here!

  • I just did a quick test and this is not an issue that I’m seeing. (WP 4.7.5, ACF 5.5.14 and Twenty Fifteen theme)

    The issue could be caused by another plugin or a filter in your theme. Try deactivating plugins and changing themes to see if you can narrow down what’s causing it.

  • I’ve been having this issue for some time. I’m skeptical that it’s due to a plugin conflict or my theme, but I haven’t totally ruled it out.

    I went in to edit the field group, which is correctly showing the “Save Custom” toggle turned on. Then I looked at the HTML source for the editing screen:

    <div class="acf-true-false">
    	<input type="hidden" name="acf_fields[39393][save_custom]" value="0"/>	<label>
    		<input type="checkbox" id="acf_fields-39393-save_custom" name="acf_fields[39393][save_custom]" value="1" class="acf-switch-input" autocomplete="off" checked="checked"/>
    		<div class="acf-switch -on"><span class="acf-switch-on">Yes</span><span class="acf-switch-off">No</span><div class="acf-switch-slider"></div></div>		<span class="message">Save 'custom' values to the field's choices</span>	</label>

    Shouldn’t the hidden field have a value of “1”? How could this be due to a plugin conflict?

    *EDIT* Now that I look more closely, the checkbox input and the hidden input both have the same name attribute. This seems like a problem. Why is the hidden field even there?

  • You are looking at the html for creating a field and not entering data.

    I did another test and I’m still not seeing any issues with saving values or adding custom values.

    Is your issue with showing the custom values on the front? What code are you using?

Viewing 4 posts - 1 through 4 (of 4 total)

The topic ‘Save 'other' values to the field's choices broken’ is closed to new replies.