Feed autodiscovery in Drupal

Someone noticed that they couldn’t easily subscribe to the RSS feed on SVBC’s site. While it is linked at the bottom of each page, they tend to be long, and really we should make it as easy as possible for folks to find it.

The reader in question was Google Reader, which of course looks in the head for something like:

<link rel="alternate" type="application/rss+xml" href="https://bikesiliconvalley.org/feed" />

The default Drupal feed shows up there, I think. I wouldn’t know, because I replace the front page and the feed with one generated by Views. However, just creating a Feed view doesn’t create that link element, you have to attach it to another view.

In SVBC’s case, we have two views that create the front page, one for the large story, and one for the secondary stories beneath it. I created a Feed, which has decent default values. I adjusted it so only certain content-types as used (content posts, instead of little one-off types, or forum threads, which are kinda odd in a feed). Then I attached it to the main story block; that inserts the link element into wherever page that block (or view; whatever it is attached to) is rendered.

It doesn’t load that feed on any other page, but for autodiscovery purposes it is okay for the moment. However, I just had an idea… Nevermind. Too much work to hack at Drupal, to do what so many other web applications do out of the box.