Home › Forums › ACF PRO › Import PHP generated fields into ACF GUI › Reply To: Import PHP generated fields into ACF GUI
Most of these functions to not have documentation, you need to dig around in ACF code. After the field group is completely set up, get the field group.
$group = acf_get_field_group[$group_key];
then get the fields for the group
$group['fields'] = acf_get_fields[$group_key';
then write the field group to a file
$filename = '/aba/path/to/your/file.json'
$handle = fopen($file, 'w');
fwrite($handle, json_encode($group));
fclose($handle);
then you can download this file from the server and import it to ACF.
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Privacy Policy. If you continue to use this site, you consent to our use of cookies.