Home › Forums › Backend Issues (wp-admin) › How to add ACF fields to my custom admin page › Reply To: How to add ACF fields to my custom admin page
Hi,
I just had the same problem and found out that you can call the following ACF functions manually, since no ACF location rule can be applied in this case, to render ACF fields in a custom admin page:
1) Load ACF JS (Ref: https://github.com/wp-premium/advanced-custom-fields-pro/blob/master/includes/assets.php#L589)
acf_enqueue_scripts();
2) Render ACF fields (Ref: https://github.com/wp-premium/advanced-custom-fields-pro/blob/master/includes/acf-field-functions.php#L570)
$fields = acf_get_fields('your_group_key');
acf_render_fields($fields);
I hope this helps!
Claudio
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.