Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add trailingslashit() to $export_path #52

Open
wants to merge 1 commit into
base: release/version3
Choose a base branch
from
Open

Add trailingslashit() to $export_path #52

wants to merge 1 commit into from

Conversation

jmslbam
Copy link
Contributor

@jmslbam jmslbam commented Aug 23, 2016

When leaving out the trailing slash the export becomes directorynamefilename.json instead of directory/filename.json and all files get exported to the same level.

Filter:

function wt_acfwpcli_fieldgroup_paths(){
    return [ get_template_directory_uri() . '/field-groups'];
}
add_filter('acfwpcli_fieldgroup_paths', 'wt_acfwpcli_fieldgroup_paths');

When leaving out the trailing slash the export becomes `directorynamefilename.json` instead of `directory/filename.json` and all files get exported to the same level.

Filter:
```
function wt_acfwpcli_fieldgroup_paths(){
    return [ get_template_directory_uri() . '/field-groups'];
}
add_filter('acfwpcli_fieldgroup_paths', 'wt_acfwpcli_fieldgroup_paths');
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant