Radio UserLand Kick Start: Using Links in an Outline

Using Links in Outline

This is part of Chapter 8 of the book Radio UserLand Kick Start by Rogers Cadenhead, published by Sams Publishing

Radio outlines can serve as hypertext documents, containing hyperlinks to URL-addressed data such as HTML pages, XML files, OPML outlines, and RSS files.

Each link is associated with the text of an item. To add a link, select the item and choose the menu command Outline, Add Link (shortcuts: Ctrl-K on Windows and Cmd-K on Macs). A dialog box opens asking for the URL to which the link connects.

Items that have hyperlinks are displayed with a blue up-arrow icon (see Figure 8.9). To see the URL of a linked item, select the item and choose Outline, Get Info.

Creating hyperlinked outlines

Figure 8.9.

Creating hyperlinked outlines. (Click to enlarge)

Hyperlinks are live when the outline is in selection mode. To visit an item's link, double-click the hyperlink icon, double-click the whitespace alongside the item, or hit keypad + (plus).

If the link connects to a Web page or similar document, that resource will be opened in a browser.

If the link connects to an OPML or RSS file, Radio will open it in the outliner, incorporating the contents of the file seamlessly into the outline. The effect is comparable to expanding an item that has subheads; after the file loads, it expands in place as one or more subheads of the linked item.

RSS feeds have their own icon in the outliner: a small newspaper (also shown in Figure 8.9). Double-clicking the item opens the items in the feed, enabling you to use the outliner as an RSS reader.

OPML files are being employed in varied ways on Radio weblogs and other Radio-created sites.

The link feature of Radio's outliner makes it possible to use the software as a bookmark manager and publish the bookmarks on the Web in a Yahoo-style directory.

To create an outline for this purpose, group linked items together under a common parent. Give the parent a descriptive name but do not associate a link with it. One example: Provide links to several online bookstores under a parent called "Books".

Figure 8.10 shows a portion of an outline used for organizing Web bookmarks.

Managing bookmarks in an outline

Figure 8.10.

Managing bookmarks in an outline. (Click to enlarge)

The bookmarks outline can have as many levels as desired. It should be saved in a folder that will be upstreamed to the Web in OPML format. One place that's suitable for this purpose, under Radio's default configuration, is its www\gems folder.

After saving the outline to an upstreaming folder, check Radio's Events page. When the outline has been published, its URL will show up in an event description.

To publish a directory using this OPML file, you place the radio.macros.directoryFrame() macro on a Web page managed by Radio (such as a new story). This macro takes an OPML file on the Web and renders it on a UserLand server, placing it inside an HTML IFRAME tag to make it appear as if it were part of a page on your site.

The macro has only one required parameter: the URL of the OPML file. Here's an example:

<%radio.macros.directoryFrame ("")%>

Tip: This example uses an OPML file containing hundreds of bookmarks to sites that I use. I publish the outline on my weblog and maintain the file with Radio's outliner, adding and removing bookmarks as old sites disappear and new favorites are discovered. To take a look at this file in Radio's outliner, choose File, Open URL and enter the bookmark file's URL.

Once the story has been published, its URL will be shown on Radio's Events page.

The directoryFrame() macro can be called with several optional parameters to specify things such as the appearance of the directory frame. The following example specifies a frame that's 1,500 pixels tall, 600 pixels wide, and has links on the text of each item:

<%radio.macros.directoryFrame ("", height:"1500", width:"600", flLinkText:"true")%>

UserLand documentation on the directoryFrame() macro can be found on Outliners.Com.

Chapter 8:

  1. Introduction
  2. Understanding Outlines
  3. Writing an Outline
  4. Modifying an Outline
  5. Viewing an Outline
  6. Using Links in an Outline
  7. Summary

Radio UserLand Kick Start home page