mamamusings: August 22, 2003

elizabeth lane lawley's thoughts on technology, academia, family, and tangential topics

Friday, 22 August 2003

mt courseware documentation and templates

Okay, I think I’ve “gone about as fur as ah c’n go” for this first version of the courseware. I’m ready to call it version 1.0, I guess, with all the caveats that go along with that.

You can see it in action on my fall course site, though I’d respectfully ask that you not post comments related to the courseware itself there—it’s a production class site. This post would be a better place to discuss process.

The templates I used are linked below, but you need to know a bit about how i set the weblog up for those to be useful.

I’m using MT with mySQL, rather than the Berkeley db. That’s important on the first page, where I’m using Brad Choate’s MTSQL plug-in to prevent post-dated items from showing up until their date rolls around. There may be a way to do that without MTSQL, but that’s the approach I used. (*Update, 9/05*: It looks like this can be done using PHP instead; see Sillybean’s Using Movable Type as an events calendar.)

I’m using Adam Kalsey’s SimpleComments plug-in, which treats trackbacks as “remote comments” and intersperses them with the comments in chronological order. I’ve also taken out all of the comment and trackback pop-up windows, directing people to the individual entry when they click on the comment or trackback count for the entry. The advantage to this is that it doesn’t break on browsers that aren’t javascript-enabled (like my sidekick, for example), and that it means that comments are always seen in the context of the original entry, which I think is important (an idea I got from Joi). The downside of this is that trackbacks don’t automatically trigger a site rebuild, so new trackbacks are shown on the main page, but not on the individual entry until the entry is rebuilt. This problem is discussed on Phil Ringnalda’s blog, and he provides a solution that I’ve implemented. However, it’s not for the technologically faint-hearted, as it involves modifying the perl code in your MT software. (FWIW, I am not a perl programmer, but still found the instructions easy to follow.)

I’m also using php extensions on all of my files, and using php includes to put the sidebar and the titlebar files into each page. There are definitely other ways to do that, but you’d have to modify the include calls on all of the templates. One of the reasons I’m using includes is that the sidebar has the calendars, which are process-intensive to build—but putting that into a separate file, the MT engine only has to build it once, rather than for every single page. It also makes it a lot easier to change the navigation and design of the site, since all the pages call the same include files.

I turned off notification for weblogs.com and blo.gs during development, but will add it back in during the quarter so students know when I’ve updated the site. I have comments, trackbacks, and trackback autodiscovery all turned on, so as to make the site as interactive as possible.

I’m using individual, daily, and category archives. Here are the additions to the archive file template for each type of archive:

Individual archives: <$MTEntryTitle dirify=”1”$>.php
Daily archives: <$MTArchiveDate format=”%Y/%m/%d/index.php”$>
Category archives: none

Note: You don’t have to use the “dirify” option for the individual entries—it creates individual archive pages with the post title as the file name (e.g. midterm_exam.php) rather than the post number (e.g. 000023.php). I do that out of personal preference, but leaving it out won’t affect functionality.

The following categories have to be set up for the templates to work:

I also added topical categories related to the course, but the current templates don’t use those at all.

I think that’s it for configuration information. Here are the templates I’m using. They’re plain text files, but your browser will probably try to parse them as HTMl, so they’ll look odd. You can either ignore the appearance and use a file—>save command to save the raw code to your own computer, or you can right/ctrl-click on the links and save them directly.

A few of these are standard MT templates, so you can just copy and paste into the existing templates in your weblog. Most are new, however, and will have to be created using the “Create new index template” option at the top of the template listing page.

Index Templates

Archive Templates
All archive templates use the same sidebar and titlebar template that the index templates use.

The things I’m doing with comments, trackbacks, and the simplecomments plug-in are optional in terms of overall functionality…you could certainly modify the templates to use the more standard approach that default MT templates include without changing the functionality of the courseware.

So, that’s it in a nutshell. Nowhere near a plug-and-play implementation, obviously. But enough information that if you’ve got some good MT-savvy, you can implement your own version.

Anyone who’d like make this more elegant by improving on my kludgy code, or adding additional functionality is more than welcome to do so. This documentation and the accompanying templates are licensed under a Creative Commons Attribution-NonCommercial-ShareAlike License.

Posted at 6:00 PM | Permalink | Comments (4) | TrackBack (9)
more like this: courseware

recent viruses and lost opportunities

Why, oh why, doesn’t Apple take advantage of all the current virus traffic to run ads that point out that Mac users don’t get these viruses ??? It seems so obvious.

We were watching NBC news last night, and they were explaining the SOBIG virus and how it works. Not once did they mention that it only affects computers running Windows. (When I remarked about this, Gerald gently reminded me of the MS-NBC relationship. Duh.)

Even on campus, none of the dire warnings about having your computer carefully checked by the tech folks before connecting it to the network mention that Mac and Linux users aren’t affected.

What an (unseized) opportunity for Apple to push OS X. How much lost time (which equals money) goes into (a) installing security patches on MS systems and (b) cleaning up the mess that viruses make when they get past the patches? One would think that would factor into purchasing decisions up front.

Posted at 6:41 PM | Permalink | Comments (10) | TrackBack (0)
more like this: technology
Liz sipping melange at Cafe Central in Vienna