Updated: 11/14/2005; 12:47:21 AM
Redwood Asylum (emeritus)
   
...by the inmates...for the inmates...


daily link  Thursday, August 01, 2002

Radio Previous/Next Links
previous / next links mini-tutorial
"something that's bugged me a long time about radio is the clumsy navigation for archive pages. the really needed a previous/next link system! i've looked around, i've found a macro to do it, and so i thought i'd share a mini-tutorial for folks who, like me, might have trouble figuring it out at first. i finally found what i was looking for at the download page for w3cfuture.

step-by-step to previous/next links to your radio archive pages

  1. download the macro; unzip the files into your rado/macros folder
  2. add the code to your page template.  this is a little tricky, becuase you have to specify the "preHtml" and "postHtml"; the marco script supplies the link information of previous and next post.
    • the format for calling the macro is like this<%prevDaylink(preHtml, postHtml)%> and
      <%nextDaylink(preHtml,postHtml)%>, where preHtml and postHtml is the HTML code for before and after the link
    • my code in my page template for the links looks like this: <%prevDaylink("<a",">&lt;&lt; previous</a> ")%> <%nextDaylink("<a","> next</a> &gt;&gt;")%>, which produces something like this <<previous  next>>
    • watch those characters; if you're doing your html in an editor (like using remote edit, for example), the source code needs to display as above; if you see the link as text on your page instead of a link, your souce code is probably something like this prevDaylink("&lt;a","&gt;&amp;lt;&amp;lt; previous&lt;/a&gt; ")
  3. make sure your categories have the code in their page templates as well

that's it! down and dirty, adding previous/next links. "

 
10:08:56 PM
categories: Radio Fun
 


Copyright 2005 © Bruce Zimmer