Home How to implement ENT into your Radio RSS feed

How to implement ENT into your Radio RSS feed

After a few late nights, I’ve successfully implemented Easy News Topics (ENT) tags to my Radio Userland RSS feed. It wasn’t as easy as I thought it would be. It involved rooting around in the Radio.root file of my weblog and upskilling myself in UserTalk, Radio Userland’s scripting language. But mostly I stood on the shoulders of giants to get this done – Dave Winer and Matt Mower in particular.

ENT is an extension of the RSS2.0 spec. Its aim is to enable categorization of RSS items into topics. After reading about ENT and writing one of my first articles about RSS topics, I decided I wanted to actually implement ENT into my weblog. After some initial searching, I came across an article by Dave Winer called “How to extend Radio’s RSS generator”. This introduced me to 3 new “callbacks” which enable Radio developers to modify their RSS feeds. The callbacks are: writeRssNamespace, writeRssChannelElement, writeRssItemElement. The first one I successfully implemented was the namespace. I did this as follows:

1. Open up your Radio.root file.
2. Drill down to user.radio.callbacks.
3. Double-click on writeRssNamespace, then re-name “item #1” to “ent”.
4. Enter the script linked here.
5. Click “Compile”.

That was relatively easy. Implementing the item elements turned out to be trickier – particularly as the elements have attributes and are nested. It took me a while to get to grips with the UserTalk syntax, not being a programmer by trade. I bumbled around a bit and got to a stage where I juuuust about had the script right. Then I happened upon Matt Mower’s conversation with Dave Winer and finally things fell into place. Here now is my code for the writeRssItemElement script – same process as above.

But wait, there’s more. Because the ENT tags are nested, there is one more piece of scripting you need to do –  modify writeRssFile. But luckily Matt Mower, one of the authors of ENT, has already done the work – right-click here to download the script. Open this in your Radio app, and it will automatically save itself in the workspace area of Radio.root. Then you need to copy it across to the following location:
system.verbs.builtins.radio.weblog.writeRssfile

btw as a sidenote, writeRssfile is just one of many very clever scripts built-in to Radio. It’s amazing how much data there is in Radio.root, once you have a good poke around. It’s a testament to the amount of work Dave Winer must have put in to build Radio Userland, so I do sympathise with his recent posts about software developers gettin’ paid.

Anyway that’s basically it for stage 1 of implementing ENT into my Radio RSS feed. Stage 2 is to actually put some worthwhile data into my topic tags – currently I’ve just got dummy data in there. Ideally I want to dynamically generate a topic word or phrase for each weblog post, based on the contents of the post and/or the title. But I guess this is where k-collector comes in. So that’s my next project, to find out about k-collector and put some meaningful data into my shiny new ENT tags 🙂

About ReadWrite’s Editorial Process

The ReadWrite Editorial policy involves closely monitoring the tech industry for major developments, new product launches, AI breakthroughs, video game releases and other newsworthy events. Editors assign relevant stories to staff writers or freelance contributors with expertise in each particular topic area. Before publication, articles go through a rigorous round of editing for accuracy, clarity, and to ensure adherence to ReadWrite's style guidelines.

Get the biggest tech headlines of the day delivered to your inbox

    By signing up, you agree to our Terms and Privacy Policy. Unsubscribe anytime.

    Tech News

    Explore the latest in tech with our Tech News. We cut through the noise for concise, relevant updates, keeping you informed about the rapidly evolving tech landscape with curated content that separates signal from noise.

    In-Depth Tech Stories

    Explore tech impact in In-Depth Stories. Narrative data journalism offers comprehensive analyses, revealing stories behind data. Understand industry trends for a deeper perspective on tech's intricate relationships with society.

    Expert Reviews

    Empower decisions with Expert Reviews, merging industry expertise and insightful analysis. Delve into tech intricacies, get the best deals, and stay ahead with our trustworthy guide to navigating the ever-changing tech market.