A picture named radiosOutliner.gif
A special site for exploring the outliner built into Radio UserLand.


Home

FAQ

Mail

Directory

 
 

How to create a directory in Radio's Outliner

Posted by Jake Savin, 6/2/02 at 8:45:34 PM.

Directories are a hierarchy of web pages that link to other directory pages, and finally to websites.

Our directories are designed to work like the leading Web directories, Yahoo, DMOZ and Looksmart, with one important difference -- we all get to create our own directories and link them together.

Think of these directories as hierarchic and dynamic webrings. Ways of linking together expertise, where ever you might find it, and a tool that makes it easy to create all kinds of structures.

OPML is the core format 

Radio directories are open, because the format used to interchange directory outlines is open. It's called Outline Processor Markup Language, or OPML. People can and are producing OPML output from dynamic applications running in Perl and other net scripting environments. We encourage competition on both sides of this format, from outliners to dynamic server environments. Let's bootstrap a new structure for the Web, it'll be exciting if we can work together. DW

Example 

Here's an example of a directory created with Radio's outliner.

You can open the directory in Radio's outliner as follows:

1. Copy this URL to your clipboard.

2. Bring the Radio application to the front. (On Windows right-click on the Radio icon in the system tray and choose Open Radio; on Mac OS X, click the app's icon in the dock.)

3. Choose Open URL from the File menu.

4. Paste the URL.

5. Click on OK.

This is what a directory looks like in the outliner. You can expand and collapse the directory hierarchy by double-clicking on the wedges to the left of each heading. Headings which are links have an up-arrow icon. Double-clicking the icon opens the link in the browser.

How to create a driectory in your Radio site 

1. Update Radio.root.

2. Bring the Radio app to the front.

3. Choose the New command from the File menu to create a new outline.

4. Add some content to your directory. Build a structure with a few levels of depth. To link to a site from your outline, place the cursor on a headline containing the name of the site and right-click. Choose Add Link. Enter the URL of the site you want to link to, and click OK. Screen shot.

5. Choose the Save command from the File menu, and save the outline as myFirstDirectory.opml in the gems sub-folder of your www folder.

6. Go to your Events page. Copy the link to myFirstDirectory.opml. If you don't see a link to myFirstDirectory.opml, wait for a few seconds, and refresh the page.

7. Create a new Story. For the title, enter My First Directory. For the text of the story, enter the following, changing the URL to the one you copied in step #6:

<%radio.macros.directoryFrame ("http://www.myserver.com/gems/myFirstDirectory.opml")%>

8. Click the Submit button.

How to include another directory 

Suppose you want to work with someone else on a directory. You agree that they will take care of a sub-topic of your directory. To a person reading your directory the result will be "seamless" -- it will appear as if they are one directory. But you get the convenience of not having to coordinate your changes. The sub-directory, because it's stored in a separate outline, can be edited separately.

Here's an example. Check out this directory. The third item, "Editorial pages" is an inclusion, it's contained in this OPML file.

Inclusions can be recursive, in other words a directory that's included can in turn include others. You can nest them as deeply as you like.

Rules for inclusion 

A node whose type is "link" is treated as an included directory if the url ends with ".opml". Changes to included directories are reflected when the including outline is saved, or after one hour.

In other words, an included OPML document is read no more than once an hour, but when the outline that contains the link is saved, all included material is refreshed the next time it is displayed.

It's as if the two directories were one, but editorial access is completely up to the server platform you're using. You can store the OPML documents anywhere, they can be generated by any software, and will appear to be part of the including directory.

radio.macros.directoryFrame parameters 

Here's the syntax for the radio.macros.directoryFrame macro:

<%radio.macros.directoryFrame (opmlUrl, height, width, frameborder, cssUrl, flMinimalTemplate, flXmlButton, flLinkText)%>

All but the first parameter are optional. The optional parameters are:

height and width, are the height and width attributes of the directory iframe. height defaults to 1000, and width defaults to "100%".

frameborder, a number, is the thickness in pixels of the border around the directory frame.

cssUrl, a string, is the URL of an external cascading style sheet. (See CSS classes below.)

flXmlButton, a boolean, says whether to include an XML button which is a link to the directory's source OPML file. Default is true.

flLinkText, a boolean, says whether to link the text of directory items in addition to linking the icons. Default is false.

CSS classes 

You can change the appearance of the directory, by supplying the URL to an external stylesheet, for the value of the cssUrl parameter, for example:

<%radio.macros.directoryFrame ("http://www.myserver.com/gems/myDirectory.opml", "http://www.myserver.com/gems/myDirectoryStylesheet.css")%>

The directory is rendered using the following CSS classes:

directoryIcon -- the class for the td tag that contains the icon

directoryIconLink -- the class for the a-href tag for an icon-link

directoryItem -- the class for the td tag that contains the item text

directoryItemLink -- the class for the td tag that contains linked item text (when flLinkText is true)

directoryCrumbLink -- the class for the a-href tag for a "breadcrumb" link

directorySourceLink -- the class for the td tag that contains the XML button that links to the OPML source for the directory

directoryFooter -- the class for the footer that appears below the links

Questions/comments 

Please ask questions and post comments on the Radio-Outline mail list.




© Copyright 2000-2008 UserLand Software, Inc. Radio UserLand and Radio are trademarks of UserLand Software.
Last update: Tuesday, June 11, 2002 at 5:05:57 PM.
Email: webmaster@userland.com

Create your own Manila site in minutes. Everyone's doing it!    This site is edited with Radio UserLand, the first personal Web Application server for Windows and Macintosh.