Linux 软件免费装

JSON Feed (jsonfeed.org)

开发者 mantonr
redsweater
dshanske
更新时间 2024年4月5日 21:41
PHP版本: 5.6 及以上
WordPress版本: 6.5
版权: GPL-2.0+
版权网址: 版权信息

标签

feeds feed json jsonfeed

下载

1.3.1 1.4.3 1.3.0 1.4.0 1.4.1 1.4.2 1.4.5 1.2

详情介绍:

Adds a JSON Feed to your WordPress site by adding /feed/json to any URL. The JSON Feed format is a pragmatic syndication format, like RSS and Atom, but with one big difference: it's JSON instead of XML. Learn more at jsonfeed.org.

安装:

  1. Upload the plugin files to the /wp-content/plugins/jsonfeed directory, or install the plugin through the WordPress plugins screen directly.
  2. Activate the plugin through the 'Plugins' screen in WordPress

常见问题:

What is JSONFeed?

JSON Feed, a format similar to RSS and Atom but in JSON. JSON has become the developers’ choice for APIs, and that developers will often go out of their way to avoid XML. JSON is simpler to read and write, and it’s less prone to bugs.

Can I add other fields to the feed?

Yes you can! There is a filter, json_feed_item, that allows you to modify the items in the feed just before they're inserted into the feed itself. For example, if you want to add a link to a post author's archive page to the respective item in the feed, you can use the following code: ``` function wp_custom_json_feed_fields( $feed_item, $post ){ $feed_item['author']['archive_link'] = get_author_posts_url( $post->post_author ); return $feed_item; } add_filter( 'json_feed_item', 'wp_custom_json_feed_fields', 10, 2); ```

Can I write information to my posts?

This is a syndication format, which means it only represents your posts and comments as feed elements. This is read only, similar to RSS or Atom. It is not an API.

更新日志:

1.4.5 1.4.4 1.4.3 1.4.2 1.4.1 1.4.0 1.3.1 1.3.0 1.2.0 1.1.2 1.1.1 1.0