• Resolved rikardo85

    (@rikardo85)


    Hello,

    I have a folder called acfe-php which contains all ACF groups. e.g. group_62cd500349df8.php

    One of these files is for a custom block. This file contains the correct ACF fields such as text fields, radio buttons etc.

    When viewing this ACF block field group in the dashboard, some fields that are in the php file are not on display.

    If I edit/add any ACF fields within this group (dashboard), it will override the PHP file and then it will match the ACF fields that display on within the dashbaord.

    Can you please advise how I can sync*/update the dashboard ACF fields to use what’s in the php file?

    *There is no syncing option when viewing the list of field groups etc

    Any help much appreciated.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Konrad Chmielewski

    (@hwk-fr)

    Hello,

    Thanks for the feedback! The PHP/Json sync files will always prime over DB Field Groups settings on the Post Edit screen. This is a core ACF design.

    Unfortunately there is no “Sync Available” feature for the PHP files at the moment. This will come in a future version tho.

    In the meantime, if you want to Sync Back php files into the database, please follow these steps:

    – Head over your /themes/my-theme/acfe-php/ folder
    – Make a backup of your up-to-date group_abcdef123456.php file outside of the folder
    – Delete the Field Group from the ACF Field Group UI
    – The group_abcdef123456.php file should be now removed from your /acfe-php/ folder
    – Copy your backup group_abcdef123456.php file back into your /acfe-php/ folder
    – Header over your ACF Field Group UI. A new tab called “Local Field Groups” will appear on top of the UI. Click on it.
    – Your PHP Field Group should be listed here. Click on “Sync Back to DB” in order to sync the PHP file back into the database.

    You now have your database synced with the latest changed from your PHP file.

    Hope it helps!

    Have a nice day!

    Regards.

    Thread Starter rikardo85

    (@rikardo85)

    Hi Konrad,

    Thank you so much. That worked!

    Thanks again

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘PHP syncing issue’ is closed to new replies.