{"id":3912,"date":"2023-07-31T04:50:07","date_gmt":"2023-07-30T19:50:07","guid":{"rendered":"https:\/\/matoken.org\/blog\/?p=3912"},"modified":"2023-07-31T04:50:08","modified_gmt":"2023-07-30T19:50:08","slug":"json-feed-and-wordpress-plugin","status":"publish","type":"post","link":"https:\/\/matoken.org\/blog\/2023\/07\/31\/json-feed-and-wordpress-plugin\/","title":{"rendered":"JSON Feed \u3068WordPress Plugin"},"content":{"rendered":"<div class=\"paragraph\">\n<p>RSS\u3084Atom\u306ealtnative\u3068\u3057\u3066JSON\u306eJSON Feed \u3068\u3044\u3046\u3082\u306e\u304c\u3042\u308b\u3088\u3046\u3067\u3059\uff0e<\/p>\n<\/div>\n<div class=\"ulist\">\n<ul>\n<li><a href=\"https:\/\/www.jsonfeed.org\/\">JSON Feed<\/a><\/li>\n<\/ul>\n<\/div>\n<div class=\"paragraph\">\n<p>\u305d\u3093\u306a\u306b\u666e\u53ca\u3057\u3066\u3044\u306a\u3044\u611f\u3058\u3067\u3059\u304c\uff0cWordPress \u306ePlugin \u3082\u3042\u308b\u3088\u3046\u306a\u306e\u3067\u5c0e\u5165\u3057\u3066\u307f\u307e\u3057\u305f\uff0e<\/p>\n<\/div>\n<p><!--more--><\/p>\n<div class=\"ulist\">\n<ul>\n<li><a href=\"https:\/\/ja.wordpress.org\/plugins\/jsonfeed\/\">JSON Feed (jsonfeed.org) \u2013 WordPress \u30d7\u30e9\u30b0\u30a4\u30f3 | WordPress.org \u65e5\u672c\u8a9e<\/a><\/li>\n<\/ul>\n<\/div>\n<div class=\"paragraph\">\n<p>WordPress \u306eURL \u306e <code>\/feed\/json<\/code> \u82e5\u3057\u304f\u306f <code>\/?feed=json<\/code> \u4ee5\u4e0b\u306bJSON Feed \u304c\u51fa\u529b\u3055\u308c\u308b\u3088\u3046\u3067\u3059\uff0e<br \/>\n\u3053\u306esite \u3060\u3068\u3053\u3061\u3089 <a href=\"https:\/\/matoken.org\/blog\/feed\/json\" class=\"bare\">https:\/\/matoken.org\/blog\/feed\/json<\/a> \u304b\u3053\u3061\u3089 <a href=\"https:\/\/matoken.org\/blog\/?feed=json\" class=\"bare\">https:\/\/matoken.org\/blog\/?feed=json<\/a><\/p>\n<\/div>\n<div class=\"paragraph\">\n<p>jq \u306b\u6e21\u3057\u3066\u307f\u308b\u3068\u306a\u3093\u304b\u30a8\u30e9\u30fc\u306b<\/p>\n<\/div>\n<div class=\"listingblock\">\n<div class=\"content\">\n<pre>$ curl -s https:\/\/matoken.org\/blog\/feed\/json | jq . | lv\nparse error: Invalid numeric literal at line 1, column 4<\/pre>\n<\/div>\n<\/div>\n<div class=\"paragraph\">\n<p>\u982d\u306b\u30a8\u30e9\u30fc\u304c\u5165\u3063\u3066\u3044\u307e\u3059\uff0e<\/p>\n<\/div>\n<div class=\"listingblock\">\n<div class=\"content\">\n<pre>$ curl -s https:\/\/matoken.org\/blog\/feed\/json | head\n&lt;br \/&gt;\n&lt;b&gt;Notice&lt;\/b&gt;:  Undefined variable: max_page in &lt;b&gt;\/var\/lib\/wordpress\/wp-content\/plugins\/jsonfeed\/feed-json-functions.php&lt;\/b&gt; on line &lt;b&gt;54&lt;\/b&gt;&lt;br \/&gt;\n{\n    \"version\": \"https:\/\/jsonfeed.org\/version\/1.1\",\n    \"user_comment\": \"This feed allows you to read the posts from this site in any feed reader that supports the JSON Feed format. To add this feed to your reader, copy the following URL -- https:\/\/matoken.org\/blog\/feed\/json -- and add it your reader.\",\n    \"next_url\": \"https:\/\/matoken.org\/blog\/feed\/json?paged=2\",\n    \"home_page_url\": \"https:\/\/matoken.org\/blog\",\n    \"feed_url\": \"https:\/\/matoken.org\/blog\/feed\/json\",\n    \"language\": \"ja\",\n    \"title\": \"matoken&amp;#039;s meme\",<\/pre>\n<\/div>\n<\/div>\n<div class=\"paragraph\">\n<p>\u3068\u308a\u3042\u3048\u305a\uff0c\u5909\u6570\u3092\u3053\u3093\u306a\u611f\u3058\u3067<\/p>\n<\/div>\n<div class=\"listingblock\">\n<div class=\"title\"><code>\/var\/lib\/wordpress\/wp-content\/plugins\/jsonfeed\/feed-json-functions.php.org<\/code><\/div>\n<div class=\"content\">\n<pre>@@ -50,7 +50,7 @@\n }\n\n function get_json_feed_next_url() {\n-       global $paged, $wp_query;\n+       global $paged, $wp_query, $max_page;\n        if ( ! $max_page ) {\n                $max_page = $wp_query-&gt;max_num_pages;\n        }<\/pre>\n<\/div>\n<\/div>\n<div class=\"paragraph\">\n<p>\u30a8\u30e9\u30fc\u306f\u51fa\u306a\u304f\u306a\u308a\u307e\u3057\u305f\uff0e<br \/>\nJSON Feed \u304b\u3089Title \u3092\u629c\u304d\u51fa\u3057\u3066\u307f\u307e\u3057\u305f\uff0e<\/p>\n<\/div>\n<div class=\"listingblock\">\n<div class=\"content\">\n<pre>$ curl -s https:\/\/matoken.org\/blog\/feed\/json | jq  '.items[].title'\n\"asciidoctor-reveal.js v5.0.1 \u306e\u65b0\u6a5f\u80fd\u3044\u304f\u3064\u304b\"\n\"i3status\u306e\u30d5\u30a9\u30f3\u30c8\u30b5\u30a4\u30ba\u3092\u5909\u66f4\"\n\"GitWeb\u3067\u30ea\u30dd\u30b8\u30c8\u30ea\u304c404\u306b\u306a\u3063\u3066\u3057\u307e\u3046\"\n\"Twitter\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u306eFritter\u306e\u5fa9\u6d3b\u3068Feed\u306e\u524a\u9664\u3068\uff0cFeed\u306e\u4f7f\u3048\u308bfork\u306eQuacker\"\n\"\u300c\u9e7f\u5150\u5cf6Linux\u52c9\u5f37\u4f1a 2023.05\u300d\u306b\u53c2\u52a0\"\n\"\u9e7f\u5c4b\u5e02\u306b\u8a2d\u7f6e\u3055\u308c\u308b\u30de\u30a4\u30dc\u30c8\u30eb\u5411\u3051\u7d66\u6c34\u6a5f\"\n\"OpenSSH ED25519 \u306e Vanity Adress \u3092\u63a2\u3057\u3066\u307f\u308b\"\n\"Logitech Webcam C310n \u3092\u8cfc\u5165\u3068C270\u3068\u306e\u6bd4\u8f03\"\n\"Andorid \u306e\u753b\u9762\u3092PC \u306b\u8ee2\u9001\u3057\u3066\u64cd\u4f5c\u3082\u51fa\u6765\u308bScrcpy 2.0 \u3067\u30aa\u30fc\u30c7\u30a3\u30aa\u8ee2\u9001\u306b\u3082\u5bfe\u5fdc\"\n\"Flet\u2019s ADSL \u306e\u30b5\u30fc\u30d3\u30b9\u7d42\u4e86\"<\/pre>\n<\/div>\n<\/div>\n<div class=\"paragraph\">\n<p>\u3057\u304b\u3057\uff0c\u9577\u3089\u304f\u66f4\u65b0\u3055\u308c\u3066\u3044\u306a\u3044\u306e\u3067\u5225\u306e\u3082\u306e\u3092\u63a2\u3057\u305f\u307b\u3046\u304c\u826f\u3044\u304b\u3082\u3057\u308c\u306a\u3044\u3067\u3059\uff0e<\/p>\n<\/div>\n<div class=\"quoteblock\">\n<blockquote>\n<div class=\"paragraph\">\n<p>Last activity: 7 years, 7 months ago<\/p>\n<\/div>\n<\/blockquote>\n<\/div>\n<div class=\"listingblock\">\n<div class=\"title\">\u74b0\u5883<\/div>\n<div class=\"content\">\n<pre>$ dpkg-query -W wordpress php jq curl\ncurl    7.85.0-1~bpo11+1\njq      1.6-2.1\nphp     2:7.4+76\nwordpress       5.7.8+dfsg1-0+deb11u2\n$ lsb_release -dr\nDescription:    Debian GNU\/Linux 11 (bullseye)\nRelease:        11\n$ arch\nx86_64<\/pre>\n<\/div>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>RSS\u3084Atom\u306ealtnative\u3068\u3057\u3066JSON\u306eJSON Feed \u3068\u3044\u3046\u3082\u306e\u304c\u3042\u308b\u3088\u3046\u3067\u3059\uff0e JSON Feed \u305d\u3093\u306a\u306b\u666e\u53ca\u3057\u3066\u3044\u306a\u3044\u611f\u3058\u3067\u3059\u304c\uff0cWordPress \u306ePlugin \u3082\u3042\u308b\u3088\u3046\u306a\u306e\u3067\u5c0e\u5165\u3057\u3066\u307f\u307e\u3057 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"webmentions_disabled_pings":false,"webmentions_disabled":false,"activitypub_content_warning":"","activitypub_content_visibility":"","activitypub_max_image_attachments":4,"activitypub_interaction_policy_quote":"anyone","activitypub_status":"","footnotes":""},"categories":[658,7,6],"tags":[788,787],"class_list":["post-3912","post","type-post","status-publish","format-standard","hentry","category-bullseye","category-debian-linux","category-linux","tag-feed","tag-json"],"_links":{"self":[{"href":"https:\/\/matoken.org\/blog\/wp-json\/wp\/v2\/posts\/3912","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/matoken.org\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/matoken.org\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/matoken.org\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/matoken.org\/blog\/wp-json\/wp\/v2\/comments?post=3912"}],"version-history":[{"count":1,"href":"https:\/\/matoken.org\/blog\/wp-json\/wp\/v2\/posts\/3912\/revisions"}],"predecessor-version":[{"id":3913,"href":"https:\/\/matoken.org\/blog\/wp-json\/wp\/v2\/posts\/3912\/revisions\/3913"}],"wp:attachment":[{"href":"https:\/\/matoken.org\/blog\/wp-json\/wp\/v2\/media?parent=3912"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/matoken.org\/blog\/wp-json\/wp\/v2\/categories?post=3912"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/matoken.org\/blog\/wp-json\/wp\/v2\/tags?post=3912"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}