WP Manifestindependent plugin directory
manifest / developer / acf-code-helper

ACF Code Helper

This is a small helper library, whose purpose is to ease your field creation process when using the Advanced Custom Fields plugin to register fields via PHP.

★ 7stars
129composer installs

Install

Download source zip No release zip yet

This is the repository archive. It installs, but the folder name will carry the branch suffix and updates will not flow.

Install straight from GitHub with WP-CLI:

wp plugin install https://github.com/radoslavgeorgiev/acf-code-helper/archive/refs/heads/master.zip

On Packagist as radoslavgeorgiev/acf-code-helper:

composer require radoslavgeorgiev/acf-code-helper
No built-in updater. New versions won't appear under Dashboard → Updates. Install new releases yourself, or let Git Updater track the repository.

This is a small helper library, whose purpose is to ease your field creation process when using the Advanced Custom Fields plugin to register fields via PHP.

Normally, ACF allows you to create fields via PHP, as you can read at https://www.advancedcustomfields.com/resources/register-fields-via-php/. However, this process requires you to have a unique field key for each field, which is afterwards used in conditional logic statements and generally, this can be quite inconvinient.

This helper assists you by automatically generating field keys based on the name of a fields group and the name of the current field.

One of my other plugins, the Twig Framework for WordPress is a perfect match for this plugin, as the framework has built-in support for content blocks, widgets and more, which rely on this class.

Installation

  1. Download the repository as a .zip file and install as a plugin.
  2. Create some groups.

Documentation

Please check the Wiki of the project.

Author

The framework is being developed by me, Radoslav Georgiev, web developer at DigitalWerk.