Scroll to top

30/04/2022


No comments yet
Leave a reply



You can also:

Click here to reply using email Reply by email Send a webmention Send a Webmention



2022/04/30#p2

0 comments: click to leave a comment

I decided to improve my RSS feeds by adding XSL styling; it's a simplified version of pretty-feed.xsl by Matt Webb who also created about feeds.com. My version has minimal CSS which reflects the look of the site.

Styled RSS feed

To get it working properly I've had to switch from .rss files to .xml so also added the appropriate redirects in .htaccess, along with the necessary http headers to force .xml files to render in all browsers rather than automatically try to open a feed reader app.

It's been a fun little exercise that's taught me a bit about how XSL works. As posts may or may not have a title I had to learn how to return different things using <xsl:choose><xsl:when> conditions as I couldn't get the result I needed with just <xsl:if> statements.

With the redirects in place subscriptions shouldn't be affected for either the Live or Daily feeds.

No comments yet
Leave a reply



You can also:

Click here to reply using email Reply by email Send a webmention Send a Webmention



Close