International Feeds
James Holderness: I’ve just been putting together a test feed for IRI support in Atom.
I wonder how many feed consumers (from the simplest aggregator to the most complex blog search engines) support Internationalizing Domain Names in Applications?
James provided a useful test feed:
Fixing the Feed Validator was easy due to this support being built into Python:
iri=uri.decode('idna')
uri=iri.encode('idna')
It should be trivial to add support for this to FeedTools, assuming I can find a prebuilt ruby library or an easy-to-understand explanation for how to convert from
http://www.詹姆斯.com/ to http://www.xn--8ws00zhy3a.com/.
Posted by Bob Aman at
Bob, this worked for me (on Ubuntu):
sudo apt-get install libidn11-dev
gem install idn
irb
require 'rubygems'
require 'idn'
IDN::Idna.toASCII('http://www.詹姆斯.com/')
Posted by Sam Ruby
at
Excellent, thank you.
I just checked in optional support for internationalized domain names in FeedTools. FeedTools can now at least open all of his test feeds, and it seems to handle any of the links that only involve an internationalized domain name, so it reads the self link and the alternate link, but it fails to understand the enclosure, and it doesn’t yet provide the option to normalize the urls in the content.
require 'feed_tools'
feed = FeedTools::Feed.open('http://www.詹姆斯.com/atomtests/iri/everything.atom')
feed.href
=> "http://www.xn--8ws00zhy3a.com/atomtests/iri/everything.atom"
feed.link
=> "http://www.xn--8ws00zhy3a.com/atomtests/iri/"
Posted by Bob Aman
at
Atom as a Case Study
This is adapted from my talk of the same name at ETech 2006. The talk’s sections were entitled Why?, How?, What?, and Lessons?; I’ve left out What?, the description of what Atom is, since we’ve had plenty of that around here. That leaves Why we...Excerpt from ongoing at
Tim Bray on RSS 2.0 and Atom
Tim Bray: RSS 2.0 has the biggest mindshare and market share; deservedly, in my opinion. Most people, starting from scratch, would (correctly) pick 2.0 as the RSS version to go with. [cut] There are some issues with RSS 2.0. [cut] The conclusion is...Excerpt from The RSS Blog at
GentleCMS Development Log: Part 2
I have an admission to make. I hate Ruby’s URI class. There, I’ve said it. It’s out in the open, I can’t take it back. I just really don’t like it. It constantly tells me that my URIs are invalid and that I’m a...Excerpt from Sporkmonger: GentleCMS Development Log: Part 2 at
GentleCMS Development Log: Part 2
I have an admission to make. I hate Ruby’s URI class. There, I’ve said it. It’s out in the open, I can’t take it back. I just really don’t like it. It constantly tells me that my URIs are invalid and that I’m a...Excerpt from Ruby on SWiK.net at
FYI, my feed consumer (the Sage extension in Firefox) worked just fine, with the exception of the enclosure test as Sage does not yet support enclosures.
Posted by Kevin Hamilton at