WP REST API – User Meta

外掛說明

Now you have no need to make additional requests to get author info (name, display_name, first_name, last_name, user_email, user_registered date) from their id that is available in the default json response.

Now all these author data is available in ‘author_meta’ field from your json response.

For example in ‘wp-json/wp/v2/posts’ you can find default fields ‘author’ that contains only its id. With this plugin you can also find new ‘author_meta’ field that include details about author.

Before:
{

author: 1

}

After:
{

author_meta: {
ID:”1″,
display_name:”admin”,
user_nicename:”admin”,
first_name:””,
last_name:””,
user_email:”[email protected]”,
user_registered:”2016-03-01 21:25:23″
}

}

Credits

This plugin is created by Ruhul Amin

螢幕擷圖

  • screenshot-1.png

安裝方式

  1. If your wordpress version below 4.7 then 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

使用者評論

2020 年 6 月 29 日
I used it for on of my projects and happy with it. Helped me what I needed.
2018 年 3 月 23 日
Hey, When I try to activate the plugin I got this error “Parse error: syntax error, unexpected ‘[‘ in D:\hshome\rayanabd\api.crazywebtag.com\wp\wp-content\plugins\wp-rest-api-user-meta\wp_rest_api_usermeta.php on line 37” WP Version 4.9.4
2017 年 12 月 18 日
I just installed the plugin, but it always return a null value even if there is an author.
2017 年 4 月 14 日
Just installed, activated this plugin and use it without any other configuration
閱讀全部 4 則使用者評論

參與者及開發者

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

參與者

將〈WP REST API – User Meta〉外掛本地化為台灣繁體中文版

對開發相關資訊感興趣?

任何人均可瀏覽程式碼、查看 SVN 存放庫,或透過 RSS 訂閱開發記錄

變更記錄

1.0.0

  • Initial release!

1.0.1

  • Added user_email, user_nicename, first_name, last_name to the author_meta field.