Support

Account

Home Forums ACF PRO Problem on fields translation

Unread

Problem on fields translation

  • Hello

    On a project under development, I declare my fields in PHP in a mu-plugin, and to avoid doubling the declaration I disable groups under ACF Pro.

    The problem comes from my filter on the acf settings to translate my fields. It has worked very well until now but no longer works:

    add_action('acf/init', 'acf_newsettings');
    function acf_newsettings()
    {
        acf_update_setting('l10n_textdomain', 'twi');
    }

    Until now, when I generated PHP under ACF Pro, I got this type of code:
    'label' => __('Product Page Header', 'twi'),

    From now on, it no longer makes my fields translatable, and if I look at the right part allowing me to select a group of fields here is what I get:

    acf pro
    For those who can’t see the image :

    I looked for where these ‘!!’ could have come from and the only place I found was in the ACF Pro code, but I don’t understand exactly what Elliot is doing and how that could explain my problem:
    https://github.com/wp-premium/advanced-custom-fields-pro/blob/master/includes/api/api-helpers.php#LC4013

    If someone could help me, I would be very grateful.

    Loïc

Viewing 1 post (of 1 total)

The topic ‘Problem on fields translation’ is closed to new replies.