<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0">
    <channel>
        <title>markpasc.org</title>
        <link>http://markpasc.org/</link>
        <description></description>
        <language>en-us</language>
        <copyright>Copyright 2010</copyright>
        <lastBuildDate>Wed, 30 Jul 2008 12:35:45 -0800</lastBuildDate>
        <generator>http://www.sixapart.com/movabletype/</generator>
        <docs>http://www.rssboard.org/rss-specification</docs>
        
        <item>
            <title>Order</title>
            <description><![CDATA[<h2>Order for Movable Type</h2>

<p><span class="mt-enclosure mt-enclosure-file" style="display: inline;"><a href="http://markpasc.org/code/mt/order/Order-1.0.zip">Download Order 1.0 (30 July 2008)</a></span></p>

<h2>Using Order</h2>

<p>To install, unzip the archive to your MT directory. The plugin is now installed.</p>

<p>Use the provided template tags to collect and reorder template content. For example:</p>

<pre><code>&lt;mt:Order&gt;

    &lt;mt:Entries&gt;
        &lt;mt:OrderItem&gt;
            &lt;mt:setvarblock name="order_by"&gt;
                &lt;mt:EntryDate utc="1" format="%Y%m%d%H%M%S"&gt;
            &lt;/mt:setvarblock&gt;
            &lt;mt:Include module="Entry"&gt;
        &lt;/mt:OrderItem&gt;
    &lt;/mt:Entries&gt;

    &lt;mt:Comments&gt;
        &lt;mt:OrderItem&gt;
            &lt;mt:setvarblock name="order_by"&gt;
                &lt;mt:CommentDate utc="1" format="%Y%m%d%H%M%S"&gt;
            &lt;/mt:setvarblock&gt;
            &lt;mt:Include module="Comment"&gt;
        &lt;/mt:OrderItem&gt;
    &lt;/mt:Comments&gt;

&lt;/mt:Order&gt;
</code></pre>

<h2>Future enhancements</h2>

<p>None noted.</p>
]]></description>
            <link>http://markpasc.org/code/mt/order/</link>
            <guid>http://markpasc.org/code/mt/order/</guid>
            
                <category domain="http://www.sixapart.com/ns/types#category">mt</category>
            
            
            <pubDate>Wed, 30 Jul 2008 12:35:45 -0800</pubDate>
        </item>
        
        <item>
            <title>Linkblog</title>
            <description><![CDATA[<h2>Linkblog for Movable Type 4</h2>

<p><span class="mt-enclosure mt-enclosure-file"><a href="http://markpasc.org/code/mt/linkblog/linkblog-1.3.zip">Download Linkblog 1.3 (12 September 2007)</a></span></p>

<h2>Using Linkblog</h2>

<p>To install, unzip the archive to your MT directory. The plugin is now installed. Viewing your dashboard should result in the &#8220;Time to upgrade!&#8221; screen.</p>

<p>You can configure the individual blogs that should have links associated with their entries. To enable linkblogging on a blog, go to Settings &rarr; Plugins, select Link Blog 1.3, then Settings, and &#8220;Enable link blogging.&#8221; The &#8220;Link&#8221; field should then appear when editing entries on that blog.</p>

<p>To display entries&#8217; links in your templates, use the <code>&lt;MTLinkblogUrl&gt;</code> tag.</p>

<h2>Future enhancements</h2>

<p>None noted.</p>
]]></description>
            <link>http://markpasc.org/code/mt/linkblog/</link>
            <guid>http://markpasc.org/code/mt/linkblog/</guid>
            
                <category domain="http://www.sixapart.com/ns/types#category">mt</category>
            
            
            <pubDate>Wed, 05 Sep 2007 10:06:41 -0800</pubDate>
        </item>
        
        <item>
            <title>Emusic Sample Player</title>
            <description><![CDATA[<!-- guid: {d570e13b-2c22-42aa-8555-83d5a74a71fc} -->
]]></description>
            <link>http://markpasc.org/code/gm/emusic_sample_player/</link>
            <guid>http://markpasc.org/code/gm/emusic_sample_player/</guid>
            
                <category domain="http://www.sixapart.com/ns/types#category">gm</category>
            
            
            <pubDate>Sat, 10 Feb 2007 14:55:20 -0800</pubDate>
        </item>
        
        <item>
            <title>Stapler</title>
            <description><![CDATA[<h3>Stapler, a web site to news feed tool for Radio UserLand</h3>

<p class="lone"><a href="Stapler20030206.zip">Download Stapler 2.2.6 (06 February 2003, zip)</a></p>

<p class='lone'>
<a href="goodish.html" title="Actual HTML content of a single Stapler feed's page"><img src='goodish.png' width='339' height='200' style='clear: right; float: right; border-width: thin; margin: 2ex 0.5em' alt="Screenshot of a single Stapler feed's page"></a>
<a href="feeds.html" title="Actual HTML content of the Stapler Feeds page"><img src='feeds.png' width='339' height='561' style='clear: right; float: right; border-width: thin; margin: 2ex 0.5em' alt='Screenshot of Stapler Feeds page'></a>
</p>

<p>Stapler is an RSS extractor <a href="http://frontier.userland.com/tools#whatAreTools">tool</a> for <a href="http://radio.userland.com/">Radio UserLand</a>: it creates syndication feeds from web sites and other content. These feeds can be used with Radio UserLand's News Aggregator or other XML syndication software. General scripts for extracting feeds with CSS-like selectors and regular expressions are included as well as several special purpose scripts, and Stapler is expandable with your own scripts written in Radio's UserTalk language. Stapler features a full tool website for browser-based configuration and documentation. Stapler is published under <a href="LICENSE">a BSD license</a>.</p>

<p>You may also be interested in <a href="http://radiotools.evectors.it/itstories/story$num=1&sec=1">eVectors RssDistiller</a>.</p>

<p class="lone">Stapler 2.2.6 is for Radio UserLand 8. <a href="Stapler20010929.zip">Stapler 1.2.0</a> is still available for Radio UserLand 7.</p>

<h4>Installing Stapler</h4>

<ol>
<li><p class="lone">Unzip <code>Stapler.root</code> to your Radio Tools directory.</p></li>
<li><p class="lone">Open Radio's <a href="http://127.0.0.1:5335/system/pages/tools">Tools page</a>. If Stapler is disabled, enable it.</p></li>
</ol>

<h4>Upgrading Stapler</h4>

<p class='lone'><em><strong>NOTE:</strong></em> If you have a version of Stapler before 1.7.3 or 1.7.4, upgrade to 1.7.4 before upgrading to 2.2.6, or remove Stapler and install afresh.</p>

<ol>
<li><p class='lone'>Close Radio.</p></li>
<li><p class='lone'>Unzip <code>Stapler.root</code> from the archive over the one in your Radio Tools directory.</p></li>
<li><p class='lone'>Start Radio.</p></li>
</ol>

<p class="lone">If you have trouble with the install, find a bug, or have any other comments or questions, email me at <a href="mailto:stapler@markpasc.org">stapler@markpasc.org</a> with your problem.</p>

<h4>Using Stapler</h4>

<p>Open the Stapler web site with the Tools-&gt;Stapler-&gt;&quot;View in browser&quot; menu option (or by going to <a href="http://127.0.0.1:5335/Stapler/"><code>http://127.0.0.1:5335/Stapler/</code></a> in your browser). Click the <code>Help</code> option for instructions on using Stapler.</p>

<!-- <p>The tool website is designed optimally for browsers with standards support, such as current versions of Gecko-based browsers and Internet Explorer. Due to the nature of CSS, the website should be quite usable in any browser, but I have not confirmed this nor can I suggest using a browser that has <em>incorrect</em> CSS support (such as Netscape 4). Also, the Stapler logo on the tool website is a <a href="http://www.libpng.org/pub/png/">PNG</a> image with alpha transparency, which may not render correctly in some browsers; in Radio's <code>www/Stapler</code> directory, copy <code>stapler_white.png</code> over <code>stapler.png</code> to use an image without alpha transparency.</p> -->

<p>[an error occurred while processing this directive]</p>

<h4>Version history</h4>

<p class="lone">2.2.6, 6 February 2003: Radio News Errors scanner added; it makes a feed listing your subscriptions that were not successfully aggregated when Radio last did a news scan. Bug in blogHeadlines when using description length limit fixed; new "description mode" available in blogHeadlines, for easily selecting whether to use no description, the whole description, an excerpt of a given length, the first sentence, or the first paragraph.</p>

<p class="lone">2.2.5, 31 January 2003: "RSS" scanner added; this is good for making an aggregate feed from several other existing RSS feeds. Stapler should no longer try to scan when you've enabled "Work Offline."</p>

<p class="lone">2.2.4, 12 January 2003: Fixed error in counting of new items. Added Dave Winer's codeFreshener code, by way of Andy Fragen's installCodeFreshener tool.</p>

<p class="lone">2.2.3, 6 January 2003: Fixed stupid error in the Radio comments scanner; it should actually work now.</p>

<p class="lone">2.2.2, 11 October 2002: Added RSS 1.0 format. Apostrophes in scanner and format data fields are no longer incorrectly encoded to "&amp;apos;". Checkbox options are correctly updated when unchecked.</p>

<p class="lone">2.2.1, 12 August 2002: Feed descriptions are correctly written to disk. Feeds with no items no longer cause Stapler to write badly formed XML. Added radioComments scanner to provide a feed informing you of new comments to your Radio weblog. The blogHeadlines scanner ignores titles of &quot;Untitled,&quot; abbreviating the item content instead. The beforeAndAfter scanner has an &quot;Include Before and After strings&quot; option. Scanner options shown in textareas are now properly escaped. Using the &quot;Subscribe&quot; button only writes the feed to disk if the file didn't already exist. Added <code>StaplerSuite.tools.newItem (feed)</code> script for use by scanner authors.</p>

<p class="lone">2.2.6, 6 February 2003: Radio News Errors scanner added; it makes a feed listing your subscriptions that were not successfully aggregated when Radio last did a news scan. Bug in blogHeadlines when using description length limit fixed; new "description mode" available in blogHeadlines, for easily selecting whether to use no description, the whole description, an excerpt of a given length, the first sentence, or the first paragraph.</p>

<p class="lone">2.2.5, 31 January 2003: "RSS" scanner added; this is good for making an aggregate feed from several other existing RSS feeds. Stapler should no longer try to scan when you've enabled "Work Offline."</p>

<p class="lone">2.2.4, 12 January 2003: Fixed error in counting of new items. Added Dave Winer's codeFreshener code, by way of Andy Fragen's installCodeFreshener tool.</p>

<p class="lone">2.2.3, 6 January 2003: Fixed stupid error in the Radio comments scanner; it should actually work now.</p>

<p class="lone">2.2.2, 11 October 2002: Added RSS 1.0 format. Apostrophes in scanner and format data fields are no longer incorrectly encoded to "&amp;apos;". Checkbox options are correctly updated when unchecked.</p>

<p class="lone">2.2.1, 12 August 2002: Feed descriptions are correctly written to disk. Feeds with no items no longer cause Stapler to write badly formed XML. Added radioComments scanner to provide a feed informing you of new comments to your Radio weblog. The blogHeadlines scanner ignores titles of &quot;Untitled,&quot; abbreviating the item content instead. The beforeAndAfter scanner has an &quot;Include Before and After strings&quot; option. Scanner options shown in textareas are now properly escaped. Using the &quot;Subscribe&quot; button only writes the feed to disk if the file didn't already exist. Added <code>StaplerSuite.tools.newItem (feed)</code> script for use by scanner authors.</p>

<p class="lone">2.2.0, 23 July 2002: Feeds can be exported to and imported from XML files. The beforeAndAfter scanner, which makes items from whatever is between specified strings, is available. Regex scanner now uses patterns of backreferences (eg <code>\1: \2</code>) instead of groups for item data. Stapler provides an option to disable upstreaming in its publishing directory. Scanners' scanner-specific data can be presented in textareas, not just text fields.</p>

<p class="lone">2.1.0, 12 July 2002: Weather Underground scanner is fixed. The selector scanner can be called by other scanners without passing a feed. Pages in Stapler's HTTP cache more than a week old, such as those for feeds with date variables in their URLs, are deleted. The HTTP user-agent string Stapler users is settable in preferences.</p>

<p class="lone">2.0.3, 23 May 2002: Recursion problems attempting to upgrading the data file are fixed. Whether it's time to scan is calculated more safely with respect to bad input data.</p>

<p class="lone">2.0.1, 23 May 2002: The &quot;Subscribe&quot; button didn't work. Stapler would only automatically upgrade its data table before a scan; now it also does so when viewing Stapler's web page.</p>

<p class="lone">2.0.0, 21 May 2002: Stapler no longer uses the concept of sources that are grouped into feeds; there are only feeds, some of which aggregate the items of other feeds. This is a big internal change.</p>

<p><br></p>

<p class="lone">1.7.4, 5 May 2002: The blogHeadlines scraper honors posts' titles, if present. The &quot;upgradeData&quot; script is run automatically during the hourly scan if it needs running. Problem conditions discovered by the upgradeData script were displayed in dialog boxes that were sometimes too small for their messages; these errors are now written to <a href="http://127.0.0.1:5335/system/pages/eventsLog">the Radio Events Log</a>, with appropriate dialog box. Interim release before Stapler 2.0, if all goes according to plan.</p>

<p class="lone">1.7.3, 2 February 2002: fixed syntactical bug in &quot;Republish feeds&quot; script and HTML stripping bug in blogHeadlines scraper.</p>

<p class="lone">1.7.2, 1 February 2002: Directories to which to publish files are automatically created (&quot;staplerFeeds&quot; error); publish buttons and menu option work <em>all</em> the time; item links are made non-relative when scraped; blogHeadlines scraper ignores items with unchecked &quot;Home Page&quot; categories; new HTML document type and siteChanged scraper.</p>

<p class="lone">1.7.1, 22 January 2002: &quot;Upgrade data&quot; bug in which Stapler would incorrectly try to upgrade data from versions 1.1.0 and later directly to 1.7.0; #subtemplate.txt was being written out incorrectly, resulting in a totally unusable tool website.</p>

<p class="lone">1.7.0, 21 January 2002: After several prereleases, the first version of Stapler for Radio 8. Support for Radio 8's status center, filesystem-based tool website, and tool info on the tools page; subscribe to feeds within Stapler; OCS 0.4 document type and scraper for producing an OCS feed of your Stapler feeds; compact lists on main sources and feeds pages; more self-contained install.</p>

<p><br></p>

<p class="lone"><a href="Stapler20010929.zip">1.2.0, 29 September 2001</a>: Feeds can be published in RSS 0.91, RSS 0.92, or any document formats you add; feeds have &quot;View Feed&quot; pages; <a href="http://www.wunderground.com/">Weather Underground</a> scraper; feed &quot;never scanned&quot; bug fixed; more control options for scraping sources.</p>

<p class="lone">1.1.3, 30 June 2001: Feeds no longer have &quot;by Stapler&quot; appended to their titles; items without descriptions are correctly published; conversion of URLs from relative to absolute fixed; blogHeadlines scraper for making a headline feed for one's MUOTD weblog included; help pages include blogHeadlines and the options added to the regex scraper in 1.1.2.</p>

<p class="lone">1.1.2, 14 June 2001: A feed is published if its file is missing, even if there are no new items; regex scraper now works.</p>

<p class="lone">1.1.1, 13 June 2001: Fixed scraper-related bugs in the StaplerData upgrade routine.</p>

<p class="lone">1.1.0, 12 June 2001: Regular expressions scraper; <q>View Source</q> page; redesigned, non-table-based Web interface; see StaplerSuite.TODO outline in database for complete list.</p>

<p class="lone">1.0.3, 19 May 2001: Fixed hard-coded addresses. Removed my sources (hee-hee).</p>

<p class="lone">1.0.2, 19 May 2001: In the ByNumbers scraper, fixed incorrect conversion from relative to absolute URLs. Fixed when a source would not be added to the feed when its Use &lt;link/&gt; option was enabled and its feed had no template set, in StaplerSuite.scrape.</p>

<p class="lone">1.0.1, 18 May 2001: Fixed incorrect ignoring/converting of a source's <code>hours</code> property in StaplerSuite.scrape.</p>
]]></description>
            <link>http://markpasc.org/code/radio/stapler/</link>
            <guid>http://markpasc.org/code/radio/stapler/</guid>
            
                <category domain="http://www.sixapart.com/ns/types#category">radio</category>
            
            
            <pubDate>Wed, 22 Feb 2006 22:38:16 -0800</pubDate>
        </item>
        
        <item>
            <title>Kit</title>
            <description><![CDATA[<h3>Kit, a suite of page tools for Radio UserLand</h3>

<p class="lone"><a href="Kit20030128.zip">Download Kit 1.2.1 (28 January 2003, zip)</a></p>

<p>Kit is a suite of &quot;page tools&quot; for <a href="http://radio.userland.com/">Radio UserLand 8</a>, including Weblog search, an improved News Aggregator page, a web Quick Script, "Radio to the Past" for changing weblog items' dates, a web outline editor, a per-category weblog index, a subscribed feeds lister, file uploader, and the Kit dashboard. Kit is published under <a href="LICENSE">a BSD license</a>.</p>

<h4>Installing Kit</h4>

<ol>
<li><p class="lone">Unzip <code>Kit20030128.zip</code> to your Radio <code>Tools</code> directory.</p></li>
<li><p class="lone">In the Radio application, select Tools-&gt;Kit-&gt;&quot;Install pages to...&quot; and enter the directory to which to publish Kit's pages. For example, if you enter <code>system</code>, your Kit pages will be at http://127.0.0.1:5335/system/ . Installing to <code>system\pages</code> (or <code>system:pages</code>) will overwrite some of Radio's default system pages with Kit's enhanced versions; this is suggested, but if you want to leave Radio's pages alone, feel free. (If the Tools-&gt;Kit menu isn't present, you may need to restart Radio.)</p></li>
</ol>

<p class="lone">If you have problems with install, find a bug, or have any comments or questions, email me at <a href="mailto:kit@markpasc.org">kit@markpasc.org</a> with a description of your situation.</p>

<h4>Using Kit</h4>

<p>After installation, open your browser and point it at <code>http://127.0.0.1:5335/Kit/</code>. Radio will forward you to the Kit Dashboard. The dashboard has links and basic forms for Kit's other pages, and your Radio Status Center (just like on the Home Page).</p>

<p>Some features will only be enabled after checking them on the Kit Preferences page. The HTTPS news aggregation feature requires the <strong>free</strong> <a href="http://tls.macrobyte.net/">Macrobyte <abbr title="Transport Layer Security">TLS</abbr> for Radio</a> <strong>client</strong> software.</p>

<h4>Using News Aggregator</h4>

<div style='float: right;'><img src="newsForm.png" width="383" height="228" alt="Screenshot of News Aggregator's time selection form"></div>

<p>This is an enhanced version of Radio's own News Aggregator page. At the bottom is a form for controlling what news items are shown. By default, the page shows all items scanned in the last hour.</p>

<p>You can assign feeds to categories on the News Preferences page. The dropdown at the bottom of the News Aggregator page will let you view the feeds in a particular category. You can also set background colors for particular feeds on the News Preferences page.</p>

<p>Kit's News Aggregator can fix broken HTML in your scanned news items. Check the "Repair improper HTML in news items" box in the Kit Preferences page, and Kit will do its best.</p>

<p>By default, News has a simple CSS layout that resembles the stock News Aggregator's. If you want, you can hack at the strings at the top of the file to put the news items in a different (even table-based) format. Look for the script at the top that sets the <code>preText</code>, <code>postText</code>, <code>channelText</code>, and <code>itemText</code> variables.</p>

<h4>Using TrackBack</h4>

<p>After enabling TrackBack in the Kit Preferences page, it will show in the weblog post form. Paste the TrackBack URL into the box, and when your post is posted, the URL will be pinged with <a href="http://www.movabletype.org/trackback/">TrackBack</a>.</p>

<h4>Using Do</h4>

<div style='float: right;'><img src="tableBrowser.png" width="309" height="244" alt='Screenshot of using Do as a table browser'></div>

<p>Do is a web-based Quick Script. Enter the UserTalk script you want to execute and click &quot;Do.&quot; To repeat a recently executed script, click the corresponding &quot;Do:&quot; button.</p>

<p>If the expression returns a table, outline, or script, Do will &quot;pretty-print&quot; the result. That means Do is also (somewhat) useful as a table browser.</p>

<p><strong><em>Be aware</em></strong> that Do can do unsafe things like print your passwords to the screen, which is bad if done remotely and in plaintext.</p>

<h4>Using Search weblog</h4>

<p>Enter your search query and options. Search weblog will show the results, rendered in your #itemTemplate. If your #itemTemplate includes the &lt;%editButton%&gt; macro, it will be shown so you can easily edit those items. Permalinks rendered as relative links will not point at the actual item.</p>

<h4>Using Edit outline</h4>

<div style='float: right;'><img src="outliner.png" width="201" height="205" alt='Screenshot of the outline editor'></div>

<p>Edit outline is a web-based outline and script editor, using the JavaScript and CSS code from <a href="http://www.netcrucible.com/xslt/opml.htm">Joshua Allen's XSLT for OPML</a>. I wrote bits that tie the JavaScript into Radio, and modified the JavaScript to use the standard DOM and different key sequences.</p>

<p>Enter the address of your outline or script--such as <code>workspace.blog.outlines.todo</code> or <code>StaplerSuite.tools.stripHtml</code>--in the form field, and click &quot;Edit.&quot; The page will reload with the outline in it.</p>

<p>If you don't see the outline, or it's qualitatively different from the screenshot, your browser may not support the CSS, DOM, DHTML type stuff the outline editor requires. The editor also may not work in Internet Explorer, since I can't easily debug JavaScript for it.</p>

<p>Click the arrows to collapse and expand trees. Click a line's text to select it, then operate on it with these keys:</p>

<table>
    <caption>Keys for the outline editor</caption>

    <tr><th>Key</th><th>Function</th></tr>
    <tr><td>ctrl-K</td><td>Edit the link</td></tr>
    <tr><td>ctrl-\</td><td>Toggle comment</td></tr>
    <tr><td>F2</td><td rowspan="2">Edit the text</td></tr>
    <tr><td>ctrl-Enter</td></tr>
    <tr><td>Insert</td><td>Add new line</td></tr>
    <tr><td>Delete</td><td>Delete selected</td></tr>
    <tr><td>ctrl-Up</td><td rowspan="4">Move the selected line around, like in Radio's outline editor</td></tr>
    <tr><td>ctrl-Down</td></tr>
    <tr><td>ctrl-Left</td></tr>
    <tr><td>ctrl-Right</td></tr>
</table>

<p>Edit outline has callbacks for when an outline is saved. These callbacks should be in the <code>KitData.callbacks.edit.save</code> table, and have the signature <code>scriptName (adrOutline)</code>.</p>

<h4>Feeds</h4>

<p><code>feeds.txt</code> generates a list of your subscribed feeds; the file is suitable for moving to a published directory for upstreaming. It's like <a href="http://radio.weblogs.com/0100887/2002/02/24.html#a88">Jon Udell's</a>, but is intended as its own page (I have a <em>lot</em> of feeds). It also strips out passwords in feed URLs, and yields for local (<code>http://127.0.0.1:5335/</code>...) feed URLs.</p>

<p>Tweak it in a text editor if you like.</p>

<h4>Category Index</h4>

<p>Category Index (<code>categoryIndex.txt</code>) provides navigation for your (possibly topical) categories for which you don't want a full HTML rendering. Copy the <code>categoryIndex.txt</code> as <code>index.txt</code> to your categories' directories. Check the "Update category indices" checkbox on the Kit Preferences page to automatically upload these indices when you post to their categories.</p>

<h4>Put file</h4>

<p>Put file lets you upload a file directly in your browser. Select the file to upload, where to put it, and hit &quot;Put.&quot; Easy.</p>

<p>Where to put the file can be a folder or a full filename. If you specify a folder, Put file will use the same filename the browser tells Radio the file had on the uploading system. If you specify a full filename, any folders that must be created to put the file there are created--so don't inadvertently transpose two directories in the path!</p>

<p>There's currently a bug in which Put file doesn't understand the filename IE says the file had on the local system; if you use IE, specify full filenames.</p>

<h4>Radio to the Past (and Future)</h4>

<div style='float: right;'><img src="radioToThePast.png" width="329" height="153" alt='Screenshot of Radio to the Past'></div>

<p><a href="http://127.0.0.1:5335/system/pages/past">Radio to the Past</a> is the colloquial name <a href="http://radio.userland.com/discuss/">the Radio discussion group</a> gave being able to change the date on a weblog item. This tool allows you to change the date of an item you posted to the weblog. Enter the post ID (look for the <code>itemToEdit</code> argument in the &quot;Edit&quot; link on <a href="http://127.0.0.1:5335/">the Home Page</a>), set the date, and go.</p>

<p>A Radio to the Past date selector also appears on the weblog post page, if you select the &quot;Toggle Radio to the Past&quot; option in Radio's Tools->Kit menu.</p>

<p><em><strong>NOTE:</strong></em> Radio to the Past is fairly experimental. You probably shouldn't use it yet if you find parts of Radio bewildering.</p>

<p>Radio to the Past is also Radio to the Future: if you specify a time in the future, the post will be held in reserve (or cryonic suspension if you prefer) until the time you posted it (or up to a minute after). Then Radio to the Past will post (thaw) it to your weblog like any other item.</p>

<p>Another gotcha: unless you've done massive customization, moving items around in the past breaks Radio's permalinks. (Insert space-time continuum joke here.) If you plan to use Radio to the Past a lot, you may want to use an alternative set of IDs for your permalinks; Radio to the Past provides three functions for this:</p>

<dl>
<dt><code>KitSuite.past.itemnum</code></dt>
    <dd>Returns just the numerical tag for the item. Use in a comment URL or anywhere you need just a number. (I know YACCS has problems with non-numerical item IDs.)</dd>
<dt><code>KitSuite.past.permalinkID</code></dt>
    <dd>Returns the anchor name; HTML anchor names can't start with a numeral, so this is "i" followed by the itemnum above. Use in an &lt;a name/&gt; or as a container ID.</dd>
<dt><code>KitSuite.past.permalinkUrl</code></dt>
    <dd>Returns the permalink URL with the permalinkID for its #anchor. Use this in an &lt;a href/&gt;.</dd>
</dl>

<p>Each function takes the item's real itemnum as the argument. For example, you'd call KitSuite.past.permalinkUrl with something like:</p>

<blockquote><p><code>&lt;a href="<strong>&lt;% KitSuite.past.permalinkUrl ("&lt;%itemnum%&gt;") %&gt;</strong>"&gt;#&lt;/a&gt;</code></p></blockquote>

<p>Also, Radio to the Past's mechanism is exposed enough for other program authors writing weblog import tools to use. Call <code>KitSuite.past.toPast (adritem, when, touch:false)</code> and Kit will put the weblog item table at <code>adritem</code> in the right place in weblogData.root. <code>when</code> is the UserTalk date value at which to place the item. If <code>touch</code> is true, toPast will mark the affected weblog archive pages for upstreaming (so if you're importing a bunch of items, pass false).</p>

<h4>Version history</h4>

<p class="lone">1.2.1, 28 January 2003: Error when setting Kit preferences with HTTPS subscriptions enabled fixed. Error in News page when fixing HTML nesting was disabled fixed.</p>

<p class="lone">1.2.0, 19 January 2003: The just-links category index page displays item titles correctly. News Preferences can now clear colors and categories. View all items of a particular feed (the "hourglass" view) like on Radio's news page. Kit's link on the Tools page forwards to your Kit Dashboard. Weblog search will search both titles and bodies. News has a "Show all aggregated news" option (mainly for searching). News repairs broken HTML (unclosed tags and attributes) in news items. Publish RSS using your item template (your permalinks, comments links) including with expanded shortcuts (I think). Ping TrackBack URLs when entering a weblog item. Subscribe to news feeds over SSL (HTTPS); requires Macrobyte's SSL client software.</p>

<p class="lone">1.2.1, 28 January 2003: Error when setting Kit preferences with HTTPS subscriptions enabled fixed. Error in News page when fixing HTML nesting was disabled fixed.</p>

<p class="lone">1.2.0, 19 January 2003: The just-links category index page displays item titles correctly. News Preferences can now clear colors and categories. View all items of a particular feed (the "hourglass" view) like on Radio's news page. Kit's link on the Tools page forwards to your Kit Dashboard. Weblog search will search both titles and bodies. News has a "Show all aggregated news" option (mainly for searching). News repairs broken HTML (unclosed tags and attributes) in news items. Publish RSS using your item template (your permalinks, comments links) including with expanded shortcuts (I think). Ping TrackBack URLs when entering a weblog item. Subscribe to news feeds over SSL (HTTPS); requires Macrobyte's SSL client software.</p>

<p class="lone">1.1.7, 26 July 2002: Search results' permalinks now point to the published item. Clicking the time data fields on the News Aggregator page in Mozilla doesn't put the focus on the radio button, merely selects it.</p>

<p class="lone">1.1.6, 16 June 2002: A Radio to the Past date selector optionally appears on the weblog item post page.</p>

<p class="lone">1.1.5, 25 May 2002: The News page has a link to the subscriptions page. When removing its files from the system\pages or system:pages directories, Kit replaces the original files.</p>

<p class="lone">1.1.4, 23 May 2002: Radio to the Past had problems when categories were disabled; this is fixed. Radio to the Past's code for discerning the item number one entered was improved, so &quot;Edit&quot; link URLs should in fact work now.</p>

<p class="lone">1.1.3, 22 May 2002: Radio to the Past flat-out didn't work. This is fixed.</p>

<p class="lone">1.1.2, 14 May 2002: Radio to the Past wouldn't really <em>move</em> items, just copy them. Also, sometimes Radio would present the Radio to the Past CSS file rather than the HTML file. These are fixed.</p>

<p class="lone">1.1.1, 13 May 2002: Radio to the Past can now place items before item #1; the <code>year</code> option correctly reflects the selected item's year; the table-moving crasher bug mentioned in the announcement should no longer occur. (Thanks, Jeremy Bowers and Jake Savin.) The Feeds page handles malicious services with blank channel titles (such as Geeknews.net) more correctly. The Dashboard page is now automatically generated when Kit's pages are written out.</p>

<p class="lone">1.1.0, 12 May 2002: The Radio to the Past (and Future) tool was added. The Search page can search in either item bodies or titles. The Search page would error when the &quot;Automatically generate item links&quot; feature was enabled. (Thanks, Mark Woods.)</p>

<p class="lone">1.0.1, 2 May 2002: News' form's category selector was ill-behaved. Clicking in time-selection fields selects the correct time mode now. If a script in Do returns a table or outline, they are printed with <code>renderObject</code> and appropriate renderers (the previous table display code is factored into a renderer script).</p>

<p class="lone">1.0, 29 April 2002: News' form is redesigned. Showing by time limits now supplements rather than replaces showing by duration and offset. Viewing by category works. Not unsurprisingly, my patience ran out before the 0.9.x version numbers did. Kit is now self-proclaimed shareware.</p>

<p class="lone">0.9.6, 18 April 2002: Search now understands the new <code>&lt;%commentLink%&gt;</code> and <code>&lt;%itemTitle%&gt;</code> macros. (Thanks, Phil Wolff and Rob Jorgensen.) An HTML typo in News prevented the post link from working in browsers that didn't <acronym title="do what I meant">DWIM</acronym>; no longer. (Thanks, Jim McGee.) A &quot;News Preferences&quot; page for specifying colors and categories for feeds was added; the pseudomacro <code>&lt;%color%&gt;</code> in the channel and item templates are replaced with the empty string, or <code>background-color: <dfn>color</dfn>;</code> if a color is defined for that channel.</p>

<p class="lone">0.9.5, 24 March 2002: &quot;Put file&quot; correctly handles specifying a filename as where to put; it still incorrectly interprets the filename given by IE. &quot;Edit outline&quot; has outline-saved callbacks. &quot;Do&quot; handles returned tables more usefully.</p>

<p class="lone">0.9.4, 17 March 2002: &quot;Put file&quot; page and &quot;Toggle category index updates&quot; menu option added. Search results are displayed most recent first. Edit outline correctly no longer errors on only a GET parameter. &quot;Install pages to...&quot; doesn't delete pages if installing to the same directory, which previously resulted in uninstalling the pages.</p>

<p class="lone">0.9.3, 9 March 2002: Feeds list doesn't show &quot;user:pass&quot; logins anymore. Feeds list shows the upstream URL if a service URL starts with <code>http://127.0.0.1:5335/</code>. Feeds list alphabetizes by channel name instead of XML URL. Outline editor uses real owner data for its interim OPML, instead of claiming you're Bob Vila. Outline editor correctly changes outlines when submitting one in the form but one is already specified in the URL, handles scripts, and escapes HTML in outline text. Do abbreviates long scripts, and correctly deletes old scripts to make room for new ones. Category index looks each minute for new items so it can update categories' index pages. Kit remembers where you installed its pages, and keeps them there; if you change where you installed them, they are deleted from the old directory.</p>

<p class="lone">0.9.2, 4 March 2002: Fixed News Aggregator's "post" buttons. Added Feeds list and category index page. History for Do still doesn't bump after filling.</p>

<p class="lone">0.9.1, 25 February 2002: Added outline editor, 7-item history for Do. HTML in News page exposed for easier editing. The &quot;Install pages to...&quot; menu option always writes the pages, overwriting any changes to the files in the filesystem.</p>

<p class="lone">0.9, 23 February 2002: First public release. Contained do, search, and news pages.</p>
]]></description>
            <link>http://markpasc.org/code/radio/kit/</link>
            <guid>http://markpasc.org/code/radio/kit/</guid>
            
                <category domain="http://www.sixapart.com/ns/types#category">radio</category>
            
            
            <pubDate>Wed, 22 Feb 2006 22:36:24 -0800</pubDate>
        </item>
        
        <item>
            <title>Friends Tool</title>
            <description><![CDATA[<h3>Friends, a tool for Radio UserLand</h3>

<p class="lone"><a href="Friends20020202.zip">Download Friends 1.1 (02 February 2002, zip)</a></p>

<p>Friends publishes select feeds scraped for your Radio News Aggregator to a &quot;Friends&quot; page, similar to LiveJournal users'. Friends is configured through its tool website and is published under <a href="LICENSE">a BSD license</a>.</p>

<p>To install, unzip <code>Friends20020202.zip</code> to your Radio Tools directory. After enabling the tool on <a href="http://127.0.0.1:5335/system/pages/tools">Radio's tools page</a> if necessary, open <a href="http://127.0.0.1:5335/Friends/">the tool website</a> and configure it.</p>

<p class="lone">Thanks to Bill Kearney for many suggestions that made 1.1 suck less.</p>
]]></description>
            <link>http://markpasc.org/code/radio/friends/</link>
            <guid>http://markpasc.org/code/radio/friends/</guid>
            
                <category domain="http://www.sixapart.com/ns/types#category">radio</category>
            
            
            <pubDate>Wed, 22 Feb 2006 22:35:09 -0800</pubDate>
        </item>
        
        <item>
            <title>Footbridge</title>
            <description><![CDATA[<h3>Footbridge, a lightweight tool to mirror Radio categories to Advogato, LiveJournal, and Blogger API sites</h3>

<p class="lone"><a href="Footbridge20030420.zip">Download Footbridge 1.4 (20 April 2003, zip)</a></p>

<p>Footbridge is a lightweight tool to mirror Radio posts to community web sites. It will post to Advogato diaries, LiveJournal journals, and Blogger API sites including Movable Type weblogs. Footbridge is published under <a href="LICENSE">a BSD license</a>.</p>

<p>You may also be interested in UserLand's <a href="http://radio.userland.com/manilaBloggerBridgeTool">Manila-Blogger Bridge Tool</a>. Footbridge uses the same Blogger API code in Radio as the Manila-Blogger Bridge Tool.</p>

<p class="lone">If you enjoy Footbridge and wish to help continue its development and the development of nifty software like it, see the &quot;Shareware&quot; file in the Footbridge archive.</p>

<h4>Installing Footbridge</h4>

<ol>
<li><p class="lone">Unzip <code>Footbridge.root</code> to your Radio Tools directory.</p></li>
<li><p class="lone">Open Radio's <a href="http://127.0.0.1:5335/system/pages/tools">Tools page</a>. If Footbridge is disabled, enable it.</p></li>
<li><p class="lone">In the Radio application, select Tools -> Footbridge -> Install callback.</p></li>
</ol>

<h4>Upgrading Footbridge</h4>

<p>To upgrade Footbridge, unzip the <code>Footbridge.root</code> from the <code>Footbridge20030420.zip</code> file over the one in your Radio Tools directory. The next time Footbridge runs, it will make the necessary changes to upgrade your data to the new version.</p>

<h4>Configuring Footbridge</h4>

<p>You have to tell Footbridge what categories to mirror where and with what account. Go to <a href="http://127.0.0.1:5335/Footbridge/">the Footbridge configuration page</a> or select Tools -> Footbridge -> View in browser in the Radio application. Follow the links at the tops of the &quot;Category&quot; and &quot;Password&quot; columns to add any necessary categories and passwords to Radio, then configure the categories to mirror and select the Save button. (The &quot;Home Page&quot; category is the same as on the weblog post page: all posts except those for which you uncheck the Home Page checkbox will be mirrored to your &quot;Home Page&quot; category.)</p>

<p>If you're posting with the Blogger or LiveJournal protocols to somewhere besides Blogger or LiveJournal&mdash;say, a Movable Type site, or uJournal&mdash;enter the . For a Movable Type site, the URL is that of your <code>mt-xmlrpc.cgi</code> script. For LiveJournal (such as uJournal), the URL is the site's <code>/interface/flat</code> script (such as <code>http://www.ujournal.org/interface/flat</code>).</p>

<p class="lone">If you have trouble with the install, find a bug, or have any other comments or questions, email me at <a href="mailto:footbridge@markpasc.org">footbridge@markpasc.org</a> with your problem.</p>

<h4>Using Blogger API</h4>

<p>When using the <code>blogger</code> driver, use &quot;username@blog ID&quot; for your Footbridge username. For example, if your Blogger username were <code>moose</code> and your blog ID were <code>31097412</code>, you would enter <code>moose@31097412</code> as your username on <a href="http://127.0.0.1:5335/Footbridge/">the Footbridge configuration page</a>. If you were posting to the first weblog of a Movable Type site, you would enter <code>moose@1</code> as your username.</p>

<p>As with any Blogger API application, when posting to Blogger proper, you must save your FTP username and password in your Blogger settings for it to work.</p>

<h4>Version history</h4>

<p class="lone">1.4, 20 April 2003: Categories with spaces in the name (including "Home Page") were not properly saved.</p>

<p class="lone">1.3, 11 November 2002: Added &quot;URL&quot; option to post to other Blogger API and LiveJournal sites besides Blogger and LiveJournal.</p>

<p class="lone">1.2, 13 July 2002: LiveJournal &quot;Don't auto-format&quot; option added; preliminary Blogger API support.</p>

<p class="lone">1.1, 30 June 2002: &quot;Home Page&quot; is now a usable category.</p>

<p class="lone">0.1, 22 May 2002: Added LiveJournal support. First release.</p>

<!-- <p class="lone"><a href="version.html">More version history</a></p> -->
]]></description>
            <link>http://markpasc.org/code/radio/footbridge/</link>
            <guid>http://markpasc.org/code/radio/footbridge/</guid>
            
                <category domain="http://www.sixapart.com/ns/types#category">radio</category>
            
            
            <pubDate>Wed, 22 Feb 2006 22:33:54 -0800</pubDate>
        </item>
        
        <item>
            <title>blogSearch</title>
            <description><![CDATA[<h3>blogSearch, a weblog search interface for Radio UserLand weblogs</h3>

<p class="lone"><a href="blogSearch.zip">Download blogSearch (20 May 2001, zip)</a></p>

<p class="lone"><strong>NOTE:</strong> blogSearch is for Radio 7. <a href="../kit/">Kit</a> includes a weblog search tool for Radio 8. You can search your Movable Type weblog already, but <a href="/weblog/2003/02/16_search_your_weblog_with_mozilla.html">with a little help</a> can do so from the Phoenix/Firebird/Mozilla Browser navigation bar or Mozilla sidebar.</p>

<p>blogSearch is a <a href="http://radiodiscuss.userland.com/websiteTools">website tool</a> for <a href="http://radio.userland.com/">Radio UserLand</a> that offers a simple search interface to a Radio weblog. blogSearch is made available under <a href="LICENSE">a BSD license</a>.</p>

<p>To install, unzip the blogSearch.fttb file somewhere and open it in Radio UserLand. It will ask if you want to place it at myUserLandData.websiteTools.blogSearch; answer OK. The tool will come up in a table window; just close it. blogSearch is ready to use.</p>

<p>To use blogSearch, go to your <acronym title="My UserLand on the Desktop">MUOTD</acronym> tool website and select Tools at the top. Select Blog Search and use the search form to search your weblog.</p>
]]></description>
            <link>http://markpasc.org/code/radio/blogsearch/</link>
            <guid>http://markpasc.org/code/radio/blogsearch/</guid>
            
                <category domain="http://www.sixapart.com/ns/types#category">radio</category>
            
            
            <pubDate>Wed, 22 Feb 2006 22:32:52 -0800</pubDate>
        </item>
        
        <item>
            <title>Watch command</title>
            <description><![CDATA[<h3>Watch command, a command for adding highlight triggers</h3>

<p class="lone"><a href="/code/beip/watch/watch1.0.js">Download Watch command 1.0 (24 April 2003)</a></p>

<p>Watch command lets you easily add a trigger to highlight a string of text (such as a name), similar to how <kbd>/gag</kbd> lets you easily add a trigger gagging a certain string of text.</p>

<h3>Using Watch command</h3>

<p>To install:</p>

<ol>
<li>Save the script as <code>init_js\watch.txt</code>, or append it to your <code>user_init_js.txt</code>. Restart Beip so the script takes effect.</li>
<li>Create a global trigger configured as you'd like the watch triggers. (Mine are Whole Word, Match Case, and Change Foreground to RGB 128,255,128.)</li>
<li>Enter <kbd>/watch</kbd> for the text of your trigger and check the "Disabled" box.</li>
</ol>

<p>To use, type <kbd>/watch <i>name</i></kbd> to add a trigger to highlight <i>name</i>. If you're connected to a particular character, it'll set a character-specific trigger; otherwise it'll set a world-specific trigger.</p>

<!--


33e1cc710ffadaa314425492b917aaed





45eca2a4e8a0529b92872af896019116


-->
]]></description>
            <link>http://markpasc.org/code/beip/watch/</link>
            <guid>http://markpasc.org/code/beip/watch/</guid>
            
                <category domain="http://www.sixapart.com/ns/types#category">beip</category>
            
            
            <pubDate>Wed, 22 Feb 2006 22:29:37 -0800</pubDate>
        </item>
        
        <item>
            <title>Vector graphics applet</title>
            <description><![CDATA[<h3>Vector graphics applet</h3>

<p>A Java applet that lets you draw a diagram for use in the BeipMU MUD client's vector diagram drawing window.</p>

<p><a href="http://markpasc.org/code/beip/vector/VGApplet.jar">Download VGApplet.jar (applet with source)</a></p>
]]></description>
            <link>http://markpasc.org/code/beip/vector/</link>
            <guid>http://markpasc.org/code/beip/vector/</guid>
            
                <category domain="http://www.sixapart.com/ns/types#category">beip</category>
            
            
            <pubDate>Wed, 22 Feb 2006 22:28:34 -0800</pubDate>
        </item>
        
        <item>
            <title>Song spammer</title>
            <description><![CDATA[<h3>Song spammer, for annoying people with what's in your music player</h3>

<p class="lone"><a href="/code/beip/song/song.beip">Download Song spammer 1.0 (04 August 2003)</a></p>

<p>Song spammer copies the title of the currently playing song in Winamp (or <a href="http://foobar2000.hydrogenaudio.org/">Foobar2000</a> with an additional plugin) to Beip's input window, or, if you've set a command format ahead of time, sends it to the current MU* as a command. You should have BeipMU beta 2.00.145.</p>

<p class="lone"><img src="/code/beip/song/song.png" width="460" height="97" alt="A screenshot showing use of the plugin's songfmt and song commands."></p>

<h3>Using Song spammer</h3>

<p>To install:</p>

<ol>
<li>Place the <code>song.beip</code> plugin file in your Beip directory.</li>
<li>Download <a href="http://www.r1ch.net/stuff/r1dll/">r1dll</a> and put the r1dll.dll in your Beip directory. If you're using Foobar2000, get the foo_winamp_spam component too and install that.</li>
<li><p>Open your <code>user_init_js.txt</code> file and add this line to the bottom:</p>

<div class="note"><p><kbd>run('/loadmodule song.beip');</kbd></p></div>
</li>

<li><p>Typing <kbd>/song</kbd> will now paste the title of the current song in the input window. If you want to send the title in a particular command, such as a particularly formatted pose, you can type <kbd>/songfmt <var>your format</var></kbd> where <var>your format</var> is the command to send the MU* with <kbd>%%</kbd> in place of the song title. For example, to send <code>: o/~ The Sundresses - Universe.universe o/~ </code> when listening to that song, you would type <kbd>/songfmt : o/~ %% o/~ </kbd>.</p>

<p>To automatically set your format when Beip starts, add this to your <code>user_init_js.txt</code> file after the previous <code>run</code> line:</p>

<div class="note"><p><kbd>run('/songfmt <var>your format</var>');</kbd></p></div>
</li>
</ol>

<h3>Future enhancements</h3>

<ul>
<li>When Beip's MCP support is better, I'd like to support an MCP query message for what's now playing, so I can make an <kbd>np</kbd> command that shows the folks in the room like whospecies, but with what they're listening to rather than their species.</li>
</ul>
]]></description>
            <link>http://markpasc.org/code/beip/song/</link>
            <guid>http://markpasc.org/code/beip/song/</guid>
            
                <category domain="http://www.sixapart.com/ns/types#category">beip</category>
            
            
            <pubDate>Wed, 22 Feb 2006 22:25:49 -0800</pubDate>
        </item>
        
        <item>
            <title>Bubble tip toaster</title>
            <description><![CDATA[<h3>Bubble tip toaster, for "toasting" XP bubble tips from triggers</h3>

<p class="lone"><a href="/code/beip/toast/Toast1.0.zip">Download Bubble tip toaster 1.0 (24 April 2003)</a></p>

<p>Bubble tip toaster displays pop up messages from Beip triggers, using the bubble tip feature of Windows XP's tray icons. You should have BeipMU beta 2.00.145.</p>

<p class="lone"><img src="/code/beip/toast/toast.png" width="362" height="118" alt="A screenshot showing a Windows XP bubble tip."></p>

<h3>Using Bubble tip toaster</h3>

<p>To install:</p>

<ol>
<li>Place the <code>Toast.beip</code> plugin file in your Beip directory.</li>
<li><p>Open your <code>user_init_js.txt</code> file and add this line to the bottom:</p>

<div class="note"><p><kbd>run('/loadmodule Toast.beip');</kbd></p></div></li>

<li><p>Add the triggers you want. Under the "Extensions" tab, select Bubble Tip
   Toaster to pop a bubble tip containing lines that trigger your trigger.
   The "Only when: Away" option is useful for these&mdash;the trigger will only
   fire when you aren't in that BeipMU window (presumably you can see the
   line just fine if you are). I use one like:</p>

<ul>
<li>Text: <kbd>Somewhere on the muck,</kbd></li>
<li>Line Starts With</li>
<li>Only when: Away</li>
<li>Extensions: Bubble Tip Toaster</li>
</ul>

<p>to get watchfor notifications in bubble tips. You might also use one for
   important pages/whispers.</p></li>
</ol>

<h3>Future enhancements</h3>

<ul>
<li>Bring up the triggering window if the bubble tip is "activated" (clicked, but not on its Close button).</li>
</ul>
]]></description>
            <link>http://markpasc.org/code/beip/toast/</link>
            <guid>http://markpasc.org/code/beip/toast/</guid>
            
                <category domain="http://www.sixapart.com/ns/types#category">beip</category>
            
            
            <pubDate>Wed, 22 Feb 2006 22:24:33 -0800</pubDate>
        </item>
        
        <item>
            <title>TBPY</title>
            <description><![CDATA[<h3>TBPY by Mark Paschal &lt;markpasc@markpasc.org&gt;</h3>

<p class="lone"><a href="/code/tbpy/tbpy.txt">tbpy.txt</a></p>

<p>TBPY is a <a href="http://www.movabletype.org/docs/mttrackback.html">Trackback</a> server CGI for the rest of your site. Rather than accepting pings for numbered weblog entries, it accepts pings for pages of your static or dynamically generated web site. Invoke TBPY through <abbr title="Server Side Includes">SSI</abbr> to include your pages' Trackbacks and the appropriate RDF for automatic Trackback discovery, or include the RDF (static) and Trackbacks (through RSS files) yourself.</p>

<p>URLs ending in <code>index.html</code> are taken to be the same as those missing. If your pages end in <code>.php</code>, you'll have to modify the code.</p>

<h4>Installing</h4>

<ul>
<li>Get <a href="tbpy.txt">the CGI script</a>.</li>
<li>Install the CGI script somewhere it will run (eg: <code>~/public_html/trackback/tbpy.cgi</code>). Create a <code>data</code> directory below its directory (eg: <code>~/public_html/trackback/data</code>), with permissions such that your web server can create files there.</li>
<li>Configure as described below.</li>
</ul>

<h4>Configuring</h4>

<p>To insert the RDF and Trackbacks for the including page with SSI, call the script with include virtual:</p>

<blockquote><p><code>&lt;!--#include virtual="/trackback/tbpy.cgi"--></code></p></blockquote>

<p>If you don't have or want to use SSI, insert the appropriate RDF yourself. It looks like this:</p>

<blockquote><p><code>
&lt;!--
&lt;rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
         xmlns:dc="http://purl.org/dc/elements/1.1/"
         xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/">
&lt;rdf:Description rdf:about="<i>URI for this page</i>"
                 dc:identifer="<i>URI for this page</i>"
                 trackback:ping="http://www.foo.com/tb.cgi/5" />
&lt;/rdf:RDF>
-->
</code></p></blockquote>

<p>The Trackbacks will be written as <a href="http://backend.userland.com/rss091">RSS 0.91</a> in <code>.xml</code> files in your <code>data</code> directory, with the absolute URL of the page--slashes and periods replaced with underscores--for the filename. For example, Trackbacks for <code>markpasc.org/code/tbpy/</code> are saved as <code>code_tbpy_.xml</code>. </p>

<p>When inserting with SSI, TBPY reads an HTML template from the <code>template.html</code> file in the <code>tbpy.cgi</code> script's directory. The first line should be a block header, the last a block footer, and the lines in the middle are repeated for each Trackback. Variables will be replaced in the standard Python <code>% <i>dictionary</i></code> manner. The term will be replaced with an HTML comment if for some reason the value is not present.</p>

<p>For example, if you don't give a <code>template.html</code> file, TBPY will pretend the file reads:</p>

<blockquote><p><code>
&lt;div class='tb'>&lt;h4>Trackbacks (&lt;a href='%(dataUri)s'>RSS&lt;/a>)&lt;/h4>
&lt;h5>&lt;a href='%(link)s'>%(title)s&lt;/a>&lt;/h5>
&lt;p>%(description)s&lt;/p>
&lt;p class='about'>by %(blogName)s at %(date)s&lt;/p>
&lt;/div>
</code></p></blockquote>

<p>The variables available in the header and footer are:</p>

<dl>
<dt><code>resourceUri</code></dt><dd>The absolute URL of the page.</dd>
<dt><code>tbUri</code></dt><dd>The absolute URI to ping, to add a Trackback to the page.</dd>
<dt><code>dataUri</code></dt><dd>The absolute URL of the data RSS file for this page.</dd>
<dt><code>title</code></dt><dd>The title for this page.</dd>
<dt><code>description</code></dt><dd>The description for this page.</dd>
</dl>

<p>A default <code>title</code> ("Trackback for <i>url</i>") and description ("Pages and weblog entries that linked to <i>url</i>") are assigned originally. You can set your own by editing the RSS data file for a given page.</p>

<p>The variables for the individual Trackbacks are:</p>

<dl>
<dt><code>title</code></dt><dd>The title of the entry or page linking to the page, as provided in the Trackback ping.</dd>
<dt><code>link</code></dt><dd>The provided backlink URL.</dd>
<dt><code>description</code></dt><dd>The provided excerpt of the entry linking to the page.</dd>
<dt><code>blogName</code></dt><dd>The provided name of the site that sent the ping.</dd>
<dt><code>date</code></dt><dd>When the ping was sent, in <code><i>YYYY</i>-<i>MM</i>-<i>HH</i>T<i>hh</i>:<i>mm</i>Z</code> format.</dd>
</dl>

<h4>To-do</h4>

<ul>
<li>Recognize <code>index.*</code> as instead of just <code>index.html</code>.</li>
</ul>
]]></description>
            <link>http://markpasc.org/code/tbpy/</link>
            <guid>http://markpasc.org/code/tbpy/</guid>
            
                <category domain="http://www.sixapart.com/ns/types#category">code</category>
            
            
            <pubDate>Wed, 22 Feb 2006 22:16:44 -0800</pubDate>
        </item>
        
        <item>
            <title>POT.py</title>
            <description><![CDATA[<h3>Publishing-Oriented Templater by Mark Paschal &lt;markpasc@markpasc.org&gt;</h3>

<p class="lone"><a href="/code/pot_py/pot.py1.3.zip">POT.py 1.3 (zip archive)</a></p>

<p class="lone"><strong>NB:</strong> 1.2's .manifest files are incompatible with 1.3. Run with <code>-1</code> and delete your .manifest before upgrading, then run with <code>--lie</code> afterward to rebuild the .manifest file.</p>

<p class="lone"><strong>NB:</strong> 1.3 uses the Python 2.3 <code>logging</code> module. You'll need <a href="http://www.red-dove.com/python_logging.html">Vinay Sajip's compatible <code>logging</code> module</a> to run POT.py with Python 2.2.</p>

<p>POT.py is an engine for publishing HTML files with embedded Python code by FTP. POT.py requires options to tell it what to publish; these are:</p>

<dl>
<dt><code>-h <var>host</var></code></dt>
    <dd>the FTP server to which to upload</dd>
<dt><code>-u <var>user</var></code></dt>
    <dd>your username on that server</dd>
<dt><code>--pass <var>pass</var></code></dt>
    <dd>your password on that server (if omitted, POT.py will prompt you for it, so you don't have to type it on the command line)</dd>
<dt><code>-r <var>remotedir</var></code></dt>
    <dd>the directory on the server that's the &quot;root&quot; of the site</dd>
<dt><code>-L <var>localdir</var></code></dt>
    <dd>the local director that's the &quot;root&quot; of the site</dd>
</dl>

<p>POT.py will publish every file in and under the specified local root directory to the server, relative to the specified remote root directory.</p>

<h4>Dot files</h4>

<p>As exception to the above, POT.py does <em>not</em> publish any file the name of which starts with a period. (UNIX uses the period to denote a hidden file.) If you don't want to specify these options on the command line, you can save them in an <code>.ftpData</code> file in the directory where you run POT.py. This file is run as Python code; here's an example:</p>

<blockquote><p><code>
# Publish my site to myisp.net/~markpasc/<br>
user = 'markpasc'<br>
host = 'ftp.myisp.net'<br>
password = 'steak'<br>
remoteDir = '/home/markpasc/public_html'<br>
localDir = '.'
</code></p></blockquote>

<p>Since &quot;.ftpData&quot; starts with a period, the ftpData file is not published even if, as in the example, the local root directory is the current directory. POT.py employs two other special dot-files:</p>

<dl>
<dt><code>.manifest</code></dt>
    <dd>POT.py's list of what it's published. It is currently not human readable (it's a &quot;pickled&quot; dictionary).</dd>
<dt><code>.include</code></dt>
    <dd>When HTML files are parsed for Python code, POT.py first executes the contents of all the <code>.include</code> files down the directory tree from the root to the parsed file.</dd>
</dl>

<p>POT.py discovers what needs publishing by looking in its <dfn>manifest</dfn>, saved in the <code>.manifest</code> file in the root directory. POT.py keeps track of all the files it publishes, by the &quot;mtime,&quot; or last modified time, for normal files, and by the <dfn>MD5 hash</dfn> for HTML files. (Since Python code in those HTML files is executed, their uploadable results may change without their unparsed content changing.)</p>

<p>Here's a basic example:</p>

<blockquote><p><code>
<span class="potcode">&lt;?inherit('.header.html')?&gt;</span><br>
&nbsp;<br>
&lt;p&gt;Hello, world! 2 + 2 = <span class="potcode">&lt;?2+2?&gt;</span>!&lt;/p&gt;<br>
&nbsp;<br>
&lt;p&gt;The sum of 1 to 100 is <span class="potcode">&lt;?<br>
ret = 0<br>
for i in range(1,101):<br>
&nbsp; &nbsp; ret += i<br>
print ret<br>
?&gt;</span>&lt;/p&gt;<br>
&nbsp;<br>
<span class="potcode">&lt;?inherit('.footer.html')?&gt;</span>
</code></p></blockquote>

<p>POT.py parses text inside <code>&lt;?</code> and <code>?&gt;</code>, as highlighted in the example, as Python code. The example shows the difference between <dfn>expressions</dfn> and <dfn>embedded scripts</dfn>: code that can be stuffed on one line and is, syntactically, a Python expression can be placed inline like <code>&lt;?2+2?&gt;</code>. Code that doesn't count as a Python expression, such as the long script with the <code>for</code> loop, should be written as shown and must use <code>print</code> (or otherwise output to stdout) to "return" a value.</p>

<p>The example also uses POT.py's <code>inherit</code> function. POT.py provides several variables for use in your templates:</p>

<dl>
<dt><code>dynamic</code></dt>
    <dd><code>1</code> if the file is being uploaded, or <code>0</code> if it's merely being tested for change. Test <code>dynamic</code> to see if you should include content that always changes; for example, a random quote, or a real timestamp (though you should probably use the file's mtime anyway). Returning a static value when POT.py tests for change will prevent the file from uploading every time.</dd>
<dt><code>filename</code></dt>
    <dd>The base filename of the file being rendered. POT.py always evaluates pages from in their directories, so you can use <code><a href="http://python.org/doc/current/lib/module-os.path.html">os.path</a>.abspath</code> or <code><a href="http://python.org/doc/current/lib/os-file-dir.html">os</a>.getcwd</code> to get the path part.</dd>
<dt><code>include(<i>filename</i>)</code></dt>
    <dd>Evaluate the given file as a Python script. Included documents are executed in the same context as the current document, so any variables, functions, &amp;c you've declared already are available in the included document. Note the filename is relative to the parsed file&mdash;you probably only want to use this for files in the same directory. (<code>include</code> is a very simple wrapper for <code>str(Document(open(<i>filename</i>, 'r')))</code>.)</dd>
<dt><code>inherit(<i>filename</i>)</code></dt>
    <dd>Evaluate the given file as a Python script. Unlike <code>include</code>, <code>inherit</code> will look up the directory tree until it finds <i>filename</i>. Use this instead of <code>include</code> for, say, templates that you want to store in your web site's root directory.</dd>
</dl>

<h4>An example</h4>

<p>At the top of this document (in its unpublished form on my computer) is:</p>

<blockquote><p><code>
&lt;?<br>
title.append('POT.py')<br>
style += &quot;span.potcode { background-color: #0c9; }\n&quot;<br>
print inherit('.header.html')<br>
?&gt;
</code></p></blockquote>

<p><code>.header.html</code> might contain:</p>

<blockquote><p><code>
&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0//EN&quot;&gt;<br>
&lt;html&gt;&lt;head&gt;<br>
&nbsp;<br>
&lt;title&gt;<span class="potcode">&lt;?<br>
fulltitle = ''<br>
for segment in title: &nbsp;# which is a list<br>
&nbsp; &nbsp; fulltitle = segment + &quot;: &quot; + fulltitle<br>
if fulltitle: print re.sub(r'<[^>]*>', '', fulltitle)
?&gt;</span>markpasc.org&lt;/title&gt;<br>
&nbsp;<br>
&lt;style type=&quot;text/css&quot;&gt;<span class="potcode">&lt;? style ?&gt;</span>&lt;/style&gt;<br>
&nbsp;<br>
&lt;/head&gt;&lt;body&gt;<br>
&nbsp;<br>
&lt;h1&gt;<span class="potcode">&lt;? fulltitle[:-2] ?&gt;</span>&lt;/h1&gt;<br>
</code>...</p></blockquote>

<p>See how <code>.header.html</code> prints the contents of the <code>style</code> variable inside the &lt;style/&gt; tag, and collapses the <code>title</code> list to make the nice &lt;title/&gt; and leading header on this page. (Also note that the <code>inherit</code> needs <code>print</code>ed, since it's part of an embedded script, not a single expression.)</p>

<p>Whither <code>.include</code>? For one, by Python's rules, those variables <code>style</code> and <code>title</code> have to be initialized; <code>.include</code> files are good for that. Also, say a subdirectory has several subpages in it, like <a href="/code/">this site's <code>code/</code> section</a>. The sidebar can be set in a <code>sidebar</code> variable in <code>code/.include</code> and referenced in <code>.header.html</code> so all the pages under <code>code/</code> have the section's sidebar. The sidebar's HTML is only given once&mdash;or even, as is the case with this site, generated from a Python dictionary containing the names of subdirectories, project names, and descriptions.</p>

<h4>Other options</h4>

<p>Lastly, POT.py has three other command line options:</p>

<dl>
<dt><code>-1</code></dt>
    <dd>Upload once and stop running. Unless you give this option, POT.py will continue to run, rescanning the directory for changes.</p>
<dt><code>--lie</code></dt>
    <dd>Only update the manifest; don't actually upload anything. Quits after one scan, like <code>-1</code>. Useful if you are, say, converting a site over from plain HTML and have a lot of images and other content files that are already on the remote site, or if POT.py's manifest gets out of sync or encounters errors uploading.</dd>
<dt><code>-q</code></dt>
    <dd>Run quietly; that is, don't print normal narrative output, only errors. Use this if you're running POT.py from cron, etc.</dd>
</dl>

<p>POT.py is a replacement for <a href="/code/publish/">publish</a>, an HTML preprocessor I threw together in Perl, so its design is heavily informed by the shortcomings and annoyances I discovered with it, as well as some of the &quot;upstreaming&quot; architecture of <a href="http://radio.userland.com/">Radio UserLand</a>. I hope you find it as useful (or at least as thought-provoking) as I do.</p>

<h4>Version history</h4>

<p class="lone">1.3, 22 August 2003: Made <code>SpyDict</code> class a <code>dict</code>, not a <code>UserDict</code> (<strong>NB:</strong> this broke .manifest file compatibility). Use standard <code>logging</code> module. Internal stylistic improvements.</p>

<p class="lone">1.2, 29 April 2003: Added <code>inherit</code> function, to source.</p>
]]></description>
            <link>http://markpasc.org/code/pot_py/</link>
            <guid>http://markpasc.org/code/pot_py/</guid>
            
                <category domain="http://www.sixapart.com/ns/types#category">code</category>
            
            
            <pubDate>Wed, 22 Feb 2006 22:02:57 -0800</pubDate>
        </item>
        
        <item>
            <title>AtomAppCallback</title>
            <description><![CDATA[<h2>AtomAppCallback, for adding callbacks to Atom entry posting</h2>

<p><a href="http://markpasc.org/code/mt/atomappcallback/atomappcallback-1.0.zip">Download AtomAppCallback 1.0</a></p>

<p>AtomAppCallback enables the creation of Movable Type plugins that hook into the creation of new entries posted with the Atom API.</p>

<h2>Using AtomAppCallback</h2>

<p>AtomAppCallback provides three callbacks. Plugins register them in the normal way, that is:</p>

<pre><code>MT-&gt;add_callback('AtomNewEntryPreSave', 5, $plugin_obj, \&amp;my_callback);
</code></pre>

<p>The callbacks are:</p>

<h3><code>AtomNewEntryPreCreate($cb, $app, $atom_entry)</code></h3>

<p>This callback is invoked before Movable Type begins to build the MT::Entry for the given XML::Atom::Entry. Modifying <code>$atom_entry</code> will affect how the MT::Entry is built by Movable Type.</p>

<h3><code>AtomNewEntryPreSave($cb, $app, $atom_entry, $entry, $orig_entry)</code></h3>

<p>This callback is invoked when the new MT::Entry created from <code>$atom_entry</code> is being saved.</p>

<h3><code>AtomNewEntryPostSave($cb, $app, $atom_entry, $entry, $orig_entry)</code></h3>

<p>This callback is invoked when the new MT::Entry created from <code>$atom_entry</code> has just been saved.</p>

<h2>Sample plugins</h2>

<p>Two sample plugins that use these callbacks are included. If you do not wish to use them, don't install them, or disable them on the Movable Type System Overview &rarr; Plugins page.</p>

<h3>UniqueID</h3>

<p>This plugin uses the <code>AtomNewEntryPreSave</code> callback to (a) reuse the Atom entry <code>id</code>, if included in the post, as the new MT::Entry's Atom <code>id</code>, and (b) prevent creation of duplicate items posted with the same Atom <code>id</code> by interpreting the duplicate post as an update to the existing entry.</p>

<h3>KeywordSubject</h3>

<p>This plugin uses the AtomNewEntryPreCreate and AtomNewEntryPreSave callbacks to save dc:subjects in the posted Atom entry as a set of keywords instead of as a category name.</p>
]]></description>
            <link>http://markpasc.org/code/mt/atomappcallback/</link>
            <guid>http://markpasc.org/code/mt/atomappcallback/</guid>
            
                <category domain="http://www.sixapart.com/ns/types#category">mt</category>
            
            
            <pubDate>Wed, 08 Feb 2006 23:24:57 -0800</pubDate>
        </item>
        
    </channel>
</rss>
