Hey, I’m running into an annoying issue and I’m looking to find a way to debug it. I’m generating a RSS feed for my blog by using the following plugin, I’ve used it before without any issues and I’m currently using 5.0.2 and Kirby 4.7.0.
After implementing everything and using a feed validator I noticed that there’s an extra newline on top of the output that makes the xml invalid (If it doesn’t start at byte 0 of the output).
~|⇒ curl http://localhost:8080/atom.xml
<?xml version="1.0" encoding="utf-8"?><feed xmlns="http://www.w3.org/2005/Atom">
I also verified that with a Hex editor where I can see that it’s a newline character.
The snippet I’m using to render the feed has no newlines and there’s no space in front of the php tags:
<?php
echo '<?xml version="1.0" encoding="utf-8"?>'; ?><feed xmlns="http://www.w3.org/2005/Atom">
<title>The Hidden Blog</title>
<link href="<?= $link ?>"/>
Now my question: Where do I best start debugging the render pipeline to figure out where this gets introduced?
Thanks!