https://github.com/stefanzweifel/kirby-json-feed
Kirby Plugin to serve a JSON Feed
https://github.com/stefanzweifel/kirby-json-feed
json-feed kirby kirby-plugin rss-feed
Last synced: 8 months ago
JSON representation
Kirby Plugin to serve a JSON Feed
- Host: GitHub
- URL: https://github.com/stefanzweifel/kirby-json-feed
- Owner: stefanzweifel
- License: mit
- Archived: true
- Created: 2017-05-24T20:53:05.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2018-01-25T20:28:34.000Z (over 8 years ago)
- Last Synced: 2025-01-30T23:32:22.853Z (over 1 year ago)
- Topics: json-feed, kirby, kirby-plugin, rss-feed
- Language: PHP
- Homepage:
- Size: 16.6 KB
- Stars: 26
- Watchers: 5
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# kirby-json-feed
Kirby Plugin to serve a JSON Feed. This plugin implements some of the structure fields of the [JSON Feed Spec Version 1](https://jsonfeed.org/version/1).
## Installation
Put the `json-feed.php` File in the `/site/plugins/json-feed` folder.
### Advanced: Git Submodules
```shell
git submodule add https://github.com/stefanzweifel/kirby-json-feed.git site/plugins/json-feed
```
## Usage
1. Create a new page. For example "feed" (Create folder `feed` in `content` folder. Create an empty file `feed.txt` in it)
2. Create a new template `feed.php` in `/site/template/`
3. Use the following snippet to build your feed:
```php
children()->visible()->flip()->limit(10)->jsonfeed(array(
'title' => 'My Blog JSON Feed',
'feed' => url('feed')
));
?>
```
Currently the following options can be passed to the `jsonfeed` method:
- `title`: The title which should be display in the feed
- `feed`: The URL where the JSON Feed will be available (e.g http://domain.com/feed)
- `datefield`: The Field which should be used for the `date_modified` key (Defaults to `date`)
- `textfield`: The Field which should be used for the `content_html` key (Defaults to `text`)
4. Visit `/feed` on your site and you should see your new JSON RSS Feed.
## List of Supported RSS Readers
A short ongoing list of RSS Readers which already support the JSON Format.
- [Feedbin](https://feedbin.com) - [Blogpost](https://feedbin.com/blog/2017/05/22/feedbin-supports-json-feed/)
- [Newsblur](http://newsblur.com) - [Blogpost](http://blog.newsblur.com/post/160982162270/newsblur-now-supports-the-new-json-feed-spec)
Feel free to open an Issue or Pull request if you know more readers which support this new standard (Or if there's another list of supported readers).
## License
MIT