Plugin: Advanced Custom Fields (ACF)

Plugin: Advanced Custom Fields (ACF)

Will not show up in the ACF admin

A field group as a JSON file or in PHP, will not show up in the ACF admin unless you import a JSON file.

If a JSON file exists in the themes acf-json folder (default Local JSON location), that field group will be loaded without showing the field group in the ACF admin it the field group does not already exist there. You can set multiple load points. So you could have your plugin have its own folder for loading JSON files from. However, you can only have one save point, so when editing field groups in ACF the JSON files can be automatically saved, but only to one location.

Translation of labels cannot be done using JSON easily as using PHP.

  • The file format for “Local JSON” is not identical as the one you get through “Export JSON”. Second one is JSON Array but first one is just JSON. Also, the second has a “modified” field that helps him with synchronization and the first one does not. So always execute “Update” on Field Group and then download file from the folder where JSON is saved.

  • About multiple loading locations aka “load points” for acf/settings/load_json: the order inside this path array is important as for same Field Groups, last one takes precedance.

Including ACF within a plugin

Real problem is how to include ACF Pro with Composer, because of Licence key.

ACF Pro as a Composer Dependency with Encrypted License Key | Roots GitHub - ffraenz/private-composer-installer: Composer install helper outsourcing sensitive keys from the package URL into environment variables older: GitHub - PhilippBaschke/acf-pro-installer: A composer install helper for Advanced Custom Fields PRO

It’s not anymore: Store ACF pro license key in WordPress PHP configuration - Awesome ACF


Interesting related projects: awesomeacf.com For examplee, ooksanen/acf-focuspoint


Image Crop

Advanced Custom Fields: Image Aspect Ratio Crop Field Advanced Custom Fields: Image Crop Add-on


PhilippBaschke/acf-pro-installer: A composer install helper for Advanced Custom Fields PRO or similar: ffraenz/private-composer-installer: Composer install helper outsourcing sensitive keys from the package URL into environment variables


Very interesting extension to copy PHP code for ACF field:


ACF Color Picker and Gutenberg

Syncing your custom Block Editor Colour Palette with Advanced Custom Fields - Pixels & Things Synchronize Editor and ACF Color Pickers 🎨Synchronize Editor and ACF Synchronize and enhance WordPress color pickers - Noleam Synchronizing Your ACF Color Picker with Gutenberg Color Classes : Whiteley Designs


My problem with some ACF solutions

Updating via field key: The field’s key should be used when saving a new value to a post (when no value exists). This helps ACF create the correct ‘reference’ between the value and the field’s settings. source: update_field

StoutLogic/acf-migrations: Change ACF field names and keys without losing existing content.

Changing Field Keys in Advanced Custom Fields

Some idea? How to update an ACF field on all of the posts or pages


Advanced Custom Fields Extensions & Resources | Awesome ACF mcguffin/acf-quickedit-fields: WordPress Plugin implementing Column Displaying, QuickEdit and BulkEdit for Advanced Custom Fields (ACF)


How to avoid conflicts when using the ACF Local JSON feature - Awesome ACF Understanding where your ACF field group settings are coming from - Awesome ACF

Load ACF JSON files from multiple locations - Awesome ACF Register an ACF Options Page - Awesome ACF


ACF Hide Layout

date 20. May 2021 | modified 29. Dec 2023
filename: Plugins » Advanced Custom Fields aka ACF