Monday, July 22, 2002

Using Active Renderer to Manage a Blogroll

I think I’ve finally found the answer I’ve been looking for. The challenge: to create a visually appealing, functional collection of links to other blogs on the right-hand column of this site. Commonly referred to as a “blogroll”, the collection of links is a good way to show visitors where else they can go for related information. Before digging into how I made it work, a note: this isn’t really what Marc Barrot (author of activeRenderer) intended. It works (quite well, actually), but it requires some elbow grease. If you’re not comfortable doing some tweaking, then you’re best to wait for a later relase of activeRenderer which will likely make this a more straightforward process.

Here’s what I did:

  1. Download and install activeRenderer. Download activeRenderer.root and save it into the Radio UserlandTools folder on your hard drive.
  2. Shut down and restart Radio Userland.
  3. Create a sub-directory for your blogroll in the Radio Userlandwwwoutlines directory. (I called mine ‘blogroll’.)
  4. Open the Radio application, select File | New.
  5. Create your blogroll. I have seven top-level “nodes” (a node is just an entry in the outline); other than the node that says “Home”, each node has sub-nodes that contain links to specific sites. Note: you need to modify the HTML link so that it sets the link target to the parent frame. To do this, open the outline. Click on HTML then “Format text” – this will turn off the Radio Outliner’s formatting of HTML and allows you to edit the underlying HTML. Click “edit” then “find and replace” then “find”. In the “find” box, type {”>} (without the curly braces). In the replace box, type {” target=”_parent”>} (without the curly braces). This is a work-around, and Marc Barrot, the author of activeRenderer, will make this easier in upcoming versions.
  6. Save your blogroll in the directory you created above; I saved mine as Radio Userlandwwwoutlinesblogrollblogroll.opml.
  7. Create a stripped down template for the blogroll sub-directory. My template is here. (Note: save this file, or your own template, in the blogroll directory as #template.txt.)
  8. Modify your #homeTemplate.txt file (this is the template that controls the presentation of your home page). Figure out where you want the blogroll to go in the HTML. Now create an inline frame that calls the rendered HTML version of the blogroll. This is the line you need to insert:
    <iframe src= height=x width=y></iframe> (note: replace “” with your weblog URL.)
  9. Save the template.
  10. In Radio, select Radio | Publish | Weblog Home Page. Verify that it works.

If all went well, you’ve now got a blogroll that will dynamically update whenever you add new links to your blogroll. (You can see mine at my home page here.) To maintain the blogroll, just add any new links to the blogroll.opml file. When you save those changes, Radio and activeRenderer will take care of updating the HTML file on the server.

Some advantages to this approach:

  • The blogroll dynamically reloads every time a page is loaded. Regardless of what page people are visiting (it could be months or years old), they’ll still see the most current list of links.
  • You can maintain your blogroll natively in Radio.
  • Screen real estate is preserved; instead of a long list, visitors see just the few top-level nodes in your outline.
  • It looks cool.

Let me know if you have any questions!

No comments:

Post a Comment