Hi,
I’m trying to install bnomei’s kirby3-feed but am suddenly encountering this issue. I’m on:
- Kirby 4
- ZOON
- Testing on local
Steps:
- I unzipped the folder into
site/plugins
and renamedkirby3-feed
- I added the following to
site/config/config.php
:
[
'pattern' => 'feed',
'method' => 'GET',
'action' => function () {
$options = [
'url' => site()->url(),
'feedurl' => site()->url() . '/feed/',
'title' => 'Feed',
'description' => '',
'link' => site()->url(),
'urlfield' => 'url',
'titlefield' => 'title',
'datefield' => 'date',
'textfield' => 'text',
'modified' => time(),
'snippet' => 'feed/rss', // 'feed/json', 'feed/atom'
'dateformat' => 'r',
'mime' => null,
'sort' => true,
];
$feed = page('blog')->children()->listed()->flip()->limit(10)->feed($options);
return $feed;
}
],
- I added
<link rel="alternate" type="application/rss+xml" title="Latest articles" href="<?= site()->url() ?>/feed"/>
between<head>
and</head>
insite/snippets/head.php
When I go to http://localhost:8080/feed
, I get:
<rss version="2.0">
<channel>
<title>Latest articles</title>
<link>http://localhost:8080/blog</link>
<lastBuildDate>Sun, 24 Nov 2024 03:41:17 +0000</lastBuildDate>
<description>Read the latest news about our company</description>
<item>
<title>When nightmares hit too close to reality.</title>
<link>
http://localhost:8080/blog/when-nightmares-hit-too-close-to-reality
</link>
<guid>
http://localhost:8080/blog/when-nightmares-hit-too-close-to-reality
</guid>
<pubDate>Sat, 23 Nov 2024 00:00:00 +0000</pubDate>
<description></description>
</item>
<item>
<title>
Recognize psychological abuse in digital spaces for the hook & bait they are; to distract, dysregulate & divide us.
</title>
<link>
http://localhost:8080/blog/abuse-in-digital-spaces-distract-dysregulate-divide-us
</link>
<guid>
http://localhost:8080/blog/abuse-in-digital-spaces-distract-dysregulate-divide-us
</guid>
<pubDate>Fri, 22 Nov 2024 00:00:00 +0000</pubDate>
<description></description>
</item>
etc.
</channel>
</rss>
With the message This XML file does not appear to have any style information associated with it. The document tree is shown below.
on top.
And when I try to subscribe to it in my reader, it doesn’t update with anything.
The weird thing is I got it to work the other day (on an earlier iteration of my site) and I could have sworn I did the same thing then and it updated in my reader.
I appreciate any advice, thanks!
Edit: In case relevant, I have the following plugins installed:
- icon
- icons
- kirby-cookie-banner
- kirby3-feed
- kirby3-redirects
- resize
- retour
- tooltip
- versions