這個外掛並未在最新的 3 個 WordPress 主要版本上進行測試。開發者可能不再對這個外掛進行維護或提供技術支援,並可能會與更新版本的 WordPress 產生使用上的相容性問題。

WP REST API – Post Type Taxonomies

外掛說明

This plugin will add separate WordPress REST API (v2) endpoint, with all relations between existing post types and attached to them terms (taxonomies).
It is very useful when you need to create some filters, when you want to know what taxonomies are attached to the current post type.

For example what can you get, using wp-json/wp/v2/post-type-taxonomies request (empty results not included):

{
    post: [
        "category",
        "post_tag",
        "post_format"
    ],
    portfolio: [
        "technologies",
        "clients",
        "work_types"
    ]
}

Check my other useful rest-api plugins: https://wordpress.org/plugins/tags/andrew-magik-rest-api.

安裝方式

  1. Double check you have the WordPress REST (v2) API installed and active
  2. Upload the plugin folder to the /wp-content/plugins/ directory, or install the plugin through the WordPress plugins screen directly.
  3. Activate the plugin through the ‘Plugins’ screen in WordPress

常見問題集

What is the URL of this new WordPress REST API (v2) endpoint?

You get get all relations between post types and attached terms using GET request:
http://yoursite.name/wp-json/wp/v2/post-type-taxonomies

When this plugin is useful?

This plugin is very useful when you need to create some filters and when you want to know what taxonomies are attached to the current post type.

Do you have other useful REST-API plugins?

Yes, I have. You can check them by tag: https://wordpress.org/plugins/tags/andrew-magik-rest-api.

使用者評論

閱讀全部 1 則使用者評論

參與者及開發者

以下人員參與了開源軟體〈WP REST API – Post Type Taxonomies〉的開發相關工作。

參與者

變更記錄

1.0

  • Initial release!