Last I week I posed a challenge to XSLT gurus: create a FeedDemon newspaper style that groups items by their links, so that items which talk about the same thing are grouped together. My XSLT skills weren't up to the task and I was doubtful it was even possible, but thankfully I was proven wrong :)
Jon Havrda stepped in and showed how it could be done with a little JavaScript help, and I took his example and created a FeedDemon newspaper style from it. If you're viewing this in FeedDemon, just click the link below to give it a try:
Related.fdxslA few days later, XSLT whiz Radek Gontarek emailed me with another approach, which turns out to be even faster. Here's Radek's description of how it works:
What does the style do ? At the beginning the input xml file/stream is preprocessed - all links from items' descriptions are extracted and added as new child elements (<storyLink>http://</storyLink>) to parent <item> elements. Then comes the real processing (second pass): i.e. Gray Boxes plus MuenchianGrouping.If you're viewing this in FeedDemon, click the link below to see this in action:
Group by Story.fdxslThanks to all those who participated in the challenge - you helped me learn a lot about XSLT, and showed off the power of FeedDemon's newspapers in the process :)