Support

Account

Home Forums Backend Issues (wp-admin) Functions.php

Unread

Functions.php

  • I want to add my call the get_field into my functions.php so I can use it in my child theme. I tried this:

    add_action(‘init’, ‘my_function_to_add_field_groups’);
    function my_function_to_add_field_groups() {
    $section_name = get_field(‘section_name’);

    print “the $section_name”;
    }

    but the variable doesn’t appear.

Viewing 1 post (of 1 total)

The topic ‘Functions.php’ is closed to new replies.