Monday, March 15, 2010

Blogger Magic - Detecting The Blog Feed

Ever see a magician take a pack of playing cards, shuffle the deck, wave his wand over the deck, and make the Ace of Spades rise into the air? Pretty mysterious.

How about I wave my wand over my blog, and make the blog feed URL rise into your browser? You've seen a BlogList wizard - you add a blog to your bloglist. Just type in the blog URL, and it pops up the feed. How did it do that?

The answer isn't hard to see, just look in the template header, for the live blog.

You can find the feed URL, by viewing the template header.

Use View - "Page Source" with the blog displayed in your browser, or use an HTTP text proxy, to examine the blog code. There, you will find the auto discovery feed URL.

Here's the header for this blog.

<head>

...

<link href='http://blogging.nitecruzr.net/' rel='canonical'/>
<link rel="alternate" type="application/atom+xml"
title="The Real Blogger Status - Atom"
href="http://blogging.nitecruzr.net/feeds/posts/default" />
<link rel="alternate" type="application/rss+xml"
title="The Real Blogger Status - RSS"
href="http://blogging.nitecruzr.net/feeds/posts/default?alt=rss" />
<link rel="service.post" type="application/atom+xml" title="The Real Blogger Status - Atom" href="http://www.blogger.com/feeds/24069595/posts/default" />

...

</style>

There it is

http://blogging.nitecruzr.net/feeds/posts/default

You won't see anything from the template source, in "Page Elements" - "Edit HTML". You have to look at the live, rendered HTML.

Here's what you may see, in "Edit HTML".

<head>
<meta content='IE=EmulateIE7' http-equiv='X-UA-Compatible'/>
<meta content='width=1100' name='viewport'/>
<b:include data='blog' name='all-head-content'/>
<title><data:blog.pageTitle/></title>

Not all third party templates will include the crucial code snippet:

<b:include data='blog' name='all-head-content'/>

If your template is missing that line of code, no magic for you.

Enable the blog feeds from the dashboard Settings page.

To enable the newsfeeds, use the dashboard Settings - Other - "Site feed" wizard. The choice of setting for "Allow Blog Feed" affects the use of dynamic templates, and successful search engine indexing of the blog.

Now, consider possible additional details which some blogs have. Both a custom domain redirect, and a custom feed (ala FeedBurner) redirect, may provide more challenge.

You can't change the native feed URL, without a feed redirector.

Also note that the URL shown in the header displays the native URL of the feed - and reflects the value of the internal feed URL variable. If you change this header record, that won't change the internal variable. To change the URL, you need to setup a redirected feed (such as a FeedBurner feed) - then use the Post Feed Redirect setting, to point to the redirected feed.


Set the "Post Feed Redirect URL", to point to the redirected feed.



You do know, I hope, that if your blog is private, it will not publish a feed. And finally, be aware that not all online services accept a redirected feed.

Any blog with a standard header will provide the feed URL, as auto discovery.

But once you understand the details, you can Follow any blog which has the auto discovery feed URLs, defined in the blog header. Just use the "Add" wizard in "Reading list", in your dashboard - and provide the URL of the blog.

Elm0D

Author & Editor

Has laoreet percipitur ad. Vide interesset in mei, no his legimus verterem. Et nostrum imperdiet appellantur usu, mnesarchum referrentur id vim.

0 comments:

Post a Comment

Navigate» Become author for this Blog

Manual Categories