Support

Account

Home Forums General Issues Select Field – Label cut off at ':'

Solved

Select Field – Label cut off at ':'

  • Good morning,

    hope all of you are very well.

    I just updated to ACF version 4.1.8 and experiencing an unwanted change. So far I used the following pattern for my select field

    ISBN : Book Title

    Book titles often contain a ‘:’ and that worked fine so far as long as there was no space before the ‘:’ , for example

    978-0307347312 : The Joy of Living: Unlocking the Secret and Science of Happiness

    The complete book title “The Joy of Living: Unlocking the Secret and Science of Happiness” was available. If I look now into the post_meta table it seems everything behind the second ‘:’ is cut off, all is left is

    978-0307347312 : The Joy of Living

    Are the complete book titles in my database gone? Any chance to prevent the new ACF behaviour?

    Thank you very much.

    martin

  • Hi @dorjeduck

    Thanks for the feedback.

    Yes, in the latest release, I changed the split from ‘ : ‘ to ‘:’

    it seems that this is causing your issue. I’ll change it back as I think your case is more important to have fixed than the reason for the origional change.

    You can expect this in the next version (or you can downgrade to 4.1.6)

    No values will be changed, just the ‘choices’ of the select field

  • Hi @elliot,

    thanks a lot for the quick answer.

    I just looked into the source code and made the following change in line 335 of the file select.php

    $choice = explode(':', $choice, 2);

    This seems to work for my case as it limits the split to the first ‘:’ ;

    In any case thanks for your reconsideration of the change you made and your awesome plugin.

    Best and beyond

    martin

  • Hi @dorjeduck

    v4.1.8.1 will fix this issue for you!

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

The topic ‘Select Field – Label cut off at ':'’ is closed to new replies.