Singpolyma

Asyncronous Archives

Posted on

This hack combines two popular archive hacks with a new functionality in the same script. The two popular hacks included are the displaying of archive post counts in the archive list, and the re-ordering of the archive list. These two can be applied using the script with or without the third, new, functionality with is asyncronous loading of archives into the sidebar. If you don’t know what that means, try it out in my sidebar. Select an archive from the drop-down and notice that instead of being taken to the archive page, the posts in that archive are listed for you right in the sidebar. The steps to implement either part of this hack follow:

  1. Edit your blog template and add the following code directly after the <body> tag:
    <ArchivePage>
    <!– START ARCHIVE XOXO –>
    <ul class=”xoxo posts” style=”display:none;”>
    <Blogger><li><a href=”<$BlogItemPermalinkUrl$>”><BlogItemTitle><$BlogItemTitle$></BlogItemTitle></a></li></Blogger>
    </ul>
    <!– END ARCHIVE XOXO –>
    </ArchivePage>

    Note: if you have your blog marked up using hAtom or the XOXO Blog Format this step is unnecessary.

  2. Add the following code into your sidebar where you want the archive list to display:
    <div id=”archive_list”><i>Loading Archives…</i></div>
    <div id=”archive_display”></div>
    <noscript>
    <ul class=”archive-list”><BloggerArchives>
    <li><a href=”<$BlogArchiveURL$>”><$BlogArchiveName$></a></li>
    </BloggerArchives></ul>
    </noscript>

    Note to advanced users. The noscript section is necessary. You can edit it, but only if you pass two additional parameters to the function in the next step containing the code starting the list and ending the list.

  3. Add the following code into your <head> section:
    <script type=”text/javascript” src=”http://jscripts.ning.com/get.php?xn_auth=no&amp;id=1286814;
    <script type=”text/javascript”>
    //<![CDATA[
    addLoadEvent(function(){get_archive_list(‘archive_list’,’archive_display’,’format‘,sort);});
    //]]>
    </script>

    Where format is drop if you want a drop-down archive list or list if you want the archives displayed in an unordered list. sort is true to sort the archive list oldest-to-newest and false to sort newest-to-oldest.

    If you want the archive list to link to the archive pages instead of loading in the sidebar then delete the archive_display text from the code above.

  4. Save your template and republish your blog.

Advanced users may be interested in the information on the scripts behind this.

Blogger Supporting RSS?

Posted on

For the longest time Blogger has been ATOM-only. This now seems to be a thing of the past. While I can find no official announcement anywhere, RSS 2.0 feeds seem to now be available on all Blogger blogs (unless the blog has not had the index published since whenever the change was). As you would expect, while the old was, say:

http://singpolyma-tech.blogspot.com/atom.xml

They have added to this:

http://singpolyma-tech.blogspot.com/rss.xml

It’s not the nicest implementation of RSS 2.0 I’ve seen, and I’m going to keep using my hAtom2RSS-through-feedburner feed for the comment options, but this is definately a step forward for Blogger.

Tags:

What is a Reading List?

Posted on

A reading list is the organised list of all feeds that a person reads using their feed reader. There are two primary file formats for reading lists, XOXO and OPML (see What is XOXO?). Reading lists are popularly used as an import/export format for moving subscriptions between feed readers. If they are made available online they can also be used as dynamic reading lists.

Dynamic reading lists are reading lists that are aggregated by a feed reader. One folder or module is always updated to contain the most current subscriptions from the reading list. This allows users to subscribe to other users’ reading lists to see what other’s are reading, for example. Directory sites like Share Your OPML (which, as the name indicates, is anti-XOXO) also allow users to share their subscriptions en masse.

Feed readers currently supporting the dynamic reading list concept are:

Dynamic reading lists can be previewed or included as a widget in a webpage using Grazr. Grazr currently only supports OPML, but XOXO is on the todo list.

If you know of any other programs that support dynamic reading lists or other interesting uses for reading lists, please leave a comment below.

If you have any suggestions on how this introduction to reading lists could be clarified, please leave a comment below.

Trackback Inside Blogger

Posted on

It is reccomended that you use the new del.icio.us, pinging, AND trackback script. This one may still work, but I no longer actively support it.

Blogger has no native trackback capabilities. While trackback is a wonderful tool, it can sometimes just be too much of a pain for Blogger users. After all, you just went to the work of writing a wonderful post, who wants to bother making a hop over to Haloscan afterwards to send trackbacks to others? With the advent of the semi-automatic Backlinks we seem to be ever less inclined to make the extra hop.

Now, the extra hop can be a thing of the past. Install the Blogger Trackback Userscript and get trackback functionality directly from your Blogger dashboard! Every time you publish a post, the script harvests the title, permalink, and post excerpt (as well as blog title) and then displays a form on the ‘post complete’ page for trackbacks. Enter the trackback URLs one at a time and hit enter. The trackbacks will be completed AJAXially.

Much thanks to Johan’s Blogger del.icio.us helper script which facilitated much of the code for this script.

Possible Future Features

  1. Support for autodiscovery trackback RDF so that one can enter simply the post URL for a trackback and not have to use the full trackback URL
  2. Optionally try auto-trackbacking to all posts linked to from the post

Back South

Posted on

Voià, for those of you who knew it not I spent the last week in our nation’s brilliant capital of N’djamena. Went up to help Dad with some work and watch him and whatnot. Usually NDJ is dreadful, but this time it wasn’t too bad. We managed to get their computer issues worked out and Dad did a lot of other stuff for them up there. I was sick one day, which was rather nasty, but I’m better now and almost glad that I got sick because of the good that came from it 🙂 They have 5-channel satellite TV up there now, which was kinda neat. After the first night of channel surfing though I had one thing on my mind — PVR! This whole bit where you turn on the TV and a show is partly over and you can’t rewind to find out what happened before just annoys me. They had this idiotic tabloid show running about who married who and got divorced in the same day and all that retarded stuff. Lots of sitcoms, which was awesome 😀 And BBC aired a live press conference where President Bush said he would start yet another war in the Middle East, this time against the Palestinians… well actually he said he would try not to but it was a rather thinly veiled threat 😉 So I’m back now and catching up on my emails took most of the morning what with this code busted and this person wanting my code for that and this new code to look at etcetc, hehe. I wish I had more time sometimes! 😉

And now for a funny story that comes straight from last night’s sermon:

A little girl came to her grandmother one day and asked, “Grandma, how old are you?”
“Well,” said Grandma, “you see dear, when you’re as old as I am you don’t tell people your age.”
“Don’t wory, Grandma,” said the little girl assuringly, “You can trust me.”
“I’m sorry, dear, but I’m not going to tell you my age.”
The little girl realised she wasn’t getting anywhere and walked off. After twenty minutes she hadn’t showed up again and Grandma was getting curious. She checked around and found her granddaughter upstairs digging through her purse.
“What are you doing?” Grandma asked.
“Grandma,” replied the little girl, “You’re 76!”
“Why, that’s right!” said Grandma, “How did you know?”
“Well,” the little girl smiled, “I found your driver’s license and it says the year you were born. So I subtracted that from this year and figured you’re 76!”
Her grandmother was surprised, but the little girl wasn’t finished yet.
“Guess what else I found Grandma?”
“What, dear?”
“Your driver’s license also says that you got an F in sex!”

LOL! 😀