This blog has moved.

The content here has been left available for historical purposes, and should be considered out of date. For the most part, comments have been closed. If you have questions, feel free to contact me at justin.henry(at)uvm.edu. Any new material can be found at http://greengaloshes.cc. Thanks for visiting!

Archive for October, 2004

Templating WordPress, Part 3

Thursday, October 28th, 2004

I came up with a few “flavors” for this tabbed version of the template over the weekend. It now comes in grape, bubblegum, tangerine, and wintergreen, in addition to the frosty flavor that is the default.

The css files are here:

wp-tabbed-grape.css wp-tabbed-tangerine.css wp-tabbed-bubblegum.css wp-tabbed-wintergreen.css

Simple Javascript Pop-up Window

Tuesday, October 26th, 2004

This is one of those little tidbits of code I am always using, and which takes too much time to write from scratch every time I need it. This would normally be placed in an external .js file (i.e. <script src="validate.js" type="text/javascript"></script>), or placed within <script language="javascript"></script> tags in the head of an html file.

function openWin(filename) { var newWin = window.open(filename,'Window', 'width=750,height=700, left=40,top=40,scrollbars=1,menubar=1, status=0,location=0,resizable=1,directories=0'); }

To make a link that would use this function to pop up a window:

<a href="#" onClick="openWin('nameOfPageToOpenInNewWindow.html');return false;">Click here to open in a new window</a>

An interview with Neal Stephenson

Thursday, October 21st, 2004

News for Nerdicus has a great interview with renowned Science Fiction writer Neal Stephenson. Whether you’ve read any of his work or not, it’s an amusing and insightful article, in the typical Slashdot format (user moderated questions submitted to interviewee).

Templating WordPress, Part 2

Monday, October 18th, 2004

One of the problems with this template was that if I added a subcategory, it would show up on the main navigation tabs. Since the point of these tabs is to make the interface less cluttered, this behaviour was less desirable.

Setting the children argument of the wplistcats template tag to “0″ (false) is supposed to only display the “top level” categories, but this seems to be broken, as it merely removes the indenting behavior and doesn’t hide the subcategories.

A little digging found me a solution posted on sourceforge. I made the change mentioned near the bottom of wp-includes/template-functions-category.php, and this seems to have resolved it.

Another solution would be to let it indent (leaving children to default to true), and just use css to hide the nested li tags, but since this appears to be a bug, (maybe just not implemented in the current version?) it would seem more appropriate to fix it than to cover it up.

You say Trackback, I say Pingback

Sunday, October 17th, 2004

I was talking with Holly the other day about ways to improve the TechCATs blog and increase its use and effectiveness. To that effect we discussed the possibility of setting the techcats up with their own blogs and using trackbacks and pingbacks to facilitate discussion and communication.

The general idea would be that Holly would post an entry on the blog, and everyone would write a related entry in their own blogs, specify the “trackback url” for Holly’s entry in the process. By specifying the trackback, they tell the blogging software to go to Holly’s entry and post a comment with a link back to their own entry. This would have the effect of posting trackback “comments” under Holly’s entry that link back to each one of the TechCAT’s related entries. As an example, I’m specifying the trackback url for an entry in Paul Martin’s blog which mentions blogging in an educational environment.

At least that’s the general idea. From what I’ve gathered, pingbacks are a similar, but more automated method for doing the same thing. For an example of this in action, see this comment under Holly’s iTunes entry - it’s not actually a “comment”, but a “Pingback”.

Below are some docs on the subject, and I’ll update as I get a better idea of how this works.

Wordpress Docs on Trackback (includes some good links, including one to MT’s documentation on the subject) Pingback Specification A Whitepaper on Pingback vs Trackback

La Dee Da

Saturday, October 16th, 2004

music note I was cruising the TechCATs blog the recently, and stumbled on a discussion surrounding music tastes. While being a tad Mac-centric (”what’s in your iTunes’), I’ll bite.

My iTunes, and more so my iPod, has a pretty wide array of stuff on it. A few I’ve been listening to lately:

Dropkick Murphy’s DJ Happpe Dj Yoda Queen Led Zeppelin

I also enjoy listening to online radio - beatbasement.com (underground hip-hop) is a long time favorite, and I’ve just found Rat Patrol Radio (WWII era swing), which has been fun.

A WP@UVM How-To, Part 1

Wednesday, October 13th, 2004

sjc suggested I post a little follow up on my wordpress install and it’s integration into the UVM Web Template. This will be less of a “How-To” than a “this is about what I did”, so you may wish to treat them more as guidelines as anything else.

For the most part, it’s pretty much a standard install. You’ll need a mysql account and of course a zoo account. Once obtaining these, you can pretty much follow the install procedures outlined in the wp install docs.

Fixing profile.php

The biggest obstacle to the base install didn’t show up until I tried to change the default admin password. At this point, I ran into a fatal error caused by the inclusion of auth.php in profile.php - it seems the code was trying to redeclare the veriflog() function in auth.php. To repair this, I commented out the following line in ./wp-admin/profile.php:

require_once('auth.php');

That done, you should be ready to go and customize the rest of wp, including your own profile. I would recommend changing the autogenerated password to something more appropriate.

Images

In order for you to be able to upload images, you’ll need to create a directory (i.e. “images”, or “uploaded-images”) in your wp install directory, and change it’s permissions to 777. Note that this makes them writeable by anyone - ye be warned!

Once you’ve created an upload directory, you can proceed to Options->Miscellaneous in your wp admin area and enable file uploads. Be sure to fill out the path information, using the name and path of the directory you just created. If you’ve done it right, you will have an “Upload” link in your wp admin navigation. Otherwise, it should tell you that it has a problem with the directory you specify.

Setting up your WP Categories

Since your categories will be what define the different “sections” on your templated site, you’ll need to create a few first (you can always create more later on). These are what will be used in your side navigation if you decide to use the UVM Template. I have “Projects”, “Tool Box” and “Potent Potables”.

You may also want to set up categories in the links area, and add some links to those.

That’s about it for the wordpress install and configuration. Next, we’ll go over how to pull the content into the uvm template.

Ubuntu!

Sunday, October 10th, 2004

Today I helped a friend install ubuntu linux on a friends machine. He had previously been running w2k, but a fried motherboard and subsequent blue screen of death required a reinstall. Since he really doesn’t need anything more than browsing, email, and IM capabilities at the moment, it didn’t make sense to spend an entire afternoon installing the OS, then going through the endless windows updates reboots, and installs that would be required of a typical windows installation.

I believe the ubuntu install came in well under an hour, probably closer to 45 mins. Built over the Debian distro, Ubuntu basically works like a debian net-install, in that it does the base install first, then uses apt-get to download and install most of the packages. It also offers a live cd, similar to knoppix (which he had been using as a replacement until now).

I’m generally prefer kde over gnome, but I’m nonetheless impressed by the clean, user friendly set up that is provided as the default when you complete the install. It comes with firefox as the default browser, which IMO is a much better choice than Konquerer.

I’m looking into getting him printing (we didn’t have any paper to test if his printer worked), burning cd’s, and scanning next.

Quicksilver

Wednesday, October 6th, 2004

Very cool. A friend just sent me a link to something that while being kind of hard to explain is at the same time going to be one of those apps that I constantly use. Quicksilver lets me hit a keystroke, then start typing the name of an app, file or whatever i might be looking for on the system, and it instantly brings up items while I type.

MacJournal 2.5

Wednesday, October 6th, 2004

A friend of mine clued me in to MacJournal as a note-taking tool. Aside from being nice and simple, it keeps all your notes in one place, and opens up with the last set of notes you were looking at. It exports in various formats (not in XML, unfortunately), and allows for fairly rigorous organization.

What is perhaps it’s coolest feature is the “Taco” button, which you can click to get a pop-up with a simpsons quote. It’s like your own little morphine drip - you’ll never want to stop!