Home Forums ACF PRO Import/Export page empty


Import/Export page empty

    • User10

    • July 15, 2014 at 4:43 am

    I recently upgraded to ACF Pro, and for some reason my Import/Export page and the Updates page are both empty in the admin panel. I’m not seeing anything in the error logs, any idea what could be causing this?

    Note: I have ACF included in my theme rather than installed as a plugin

    • User10

    • July 15, 2014 at 6:18 am

    Setting this value:

    add_filter('acf/settings/path', function( $path ){
        return '/full/server/parth/wp-content/themes/themename/advanced-custom-fields/';

    fixed this issue. Is there a way to set this relative to the WP install location rather than a full path? The path will obviously change when I hand my theme off to clients who then use it on their own server.

    • Elliot

    • July 15, 2014 at 10:51 am

    Hi @bradwiatr

    WP contains some handy functions to retrieve urls / paths to the WP installation. Something like this should work a treat:

    include_once( get_template_directory() . '/lib/acf/acf.php' );
    add_filter('acf/settings/dir', function( $dir ){
        return get_template_directory_uri() . '/lib/acf/';
    add_filter('acf/settings/path', function( $path ){
        return get_template_directory() . '/lib/acf/';
    • Elliot

    • July 15, 2014 at 11:30 am

    Hi guys

    Just updated the docs with relevant code:

    • thomask

    • July 15, 2014 at 10:18 pm

    As in current example get_template_directory_uri() is used:

    Note that get_template_directory_uri() / get_template_directory() returns the path to the parent theme if a child theme is used.

    Better use get_stylesheet_directory_uri() / get_stylesheet_directory() to always get the currently used theme.

    • Elliot

    • July 16, 2014 at 1:42 pm

    Hi @thomask

    Nice one! I’ll update the docs

Viewing 6 posts - 1 through 6 (of 6 total)

You must be logged in to reply to this topic.

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 Cookie Policy. If you continue to use this site, you consent to our use of cookies.