This plugin is intended for developers that are using Advanced Custom Fields and Timber to develop their themes.
该插件面向使用高级自定义字段和Timber来开发主题的开发人员。 p>
By enabling this plugin the user-defined advanced custom fields will be available in the Timber context variable as follows:
通过启用此插件,用户定义的高级自定义字段将在Timber上下文变量中可用,如下所示: p>
- Fields defined for settings pages will be available everywhere under the “options” key
- 为设置页面定义的字段将在“选项”键下随处可见 li>
- Fields defined for posts, pages and custom post types will be available on the \Timber\Post object under the “fields” key
- 为帖子,页面和自定义帖子类型定义的字段将在\ Timber \ Post对象的“字段”键下提供 li>
- Fields defined for terms will be available on the \Timber\Term object under the “fields” key
- 为术语定义的字段将在\ Timber \ Term对象的“ fields”键下可用 li>
Fields defined for users will be available on the \Timber\User object under the “fields” key
为用户定义的字段将显示在\ Timber \ User对象的“字段”键下 p>
li>
Defined menus will also be available everywhere under the “menus” key
定义的菜单也将在“菜单”键下随处可见 p>
li>
- In order to reduce the amount of fields provided we limited the automatic processing to the first two levels of post fields.
- 为了减少提供的字段数量,我们将自动处理限制为发布字段的前两个级别。
That means that if you have Post A which relates Post B, which relates Post C you will get the fields for Post A and Post B, while for Post C you will get the Timber Post without the processed fields.
这意味着,如果您具有与帖子B相关联的帖子A,而与帖子C相关联,您将获得帖子A和帖子B的字段,而对于帖子C,您将获得未处理字段的木材帖子。
To modify the depth use the ‘acf_timber_posts_fields_max_depth’ filter.
要修改深度,请使用“ acf_timber_posts_fields_max_depth”过滤器。 li>
ul>
Also adds twig functions for images:
还为图像添加了树枝功能: p>