Skip to content


Tag: Wordpress

The newest version of the Sinosplice Tooltip plugin for WordPress is out! I chipped in and helped John and Andy a little bit this time with code from my pinyin tools, so it now displays pinyin with tone marks in its pop-ups.

If you have a wordpress blog and you ever put Chinese phrases into your posts, this is definitely worth checking out. With the plugin, you can enter translations or pinyin to pop-up when when your readers mouse over the Chinese characters in your post.

Here’s an example: 中秋節

You can download the plugin at its page and you can see a usage and installation tutorial on Sinosplice.

A couple days ago, Ryan and John pointed out to me that they had some usability issues with the color of the links on my site when you hover over them. I had been making them white, but that was just too hard to read on the light background of the site, especially for on some displays.

In a nod to all of the help and advice John’s given me, I immediately set the a:hover style to “Sinosplice Green“, i.e., the background color of John’s site that he’s been using since the bronze age of blogging. I was been busy with the school, and Google Docs had basically wreaked a gigantic curriculum document I’d been working on. There just wasn’t time to think about it. I just had to pick something that was readable. The only problem is that that particular color (#363) is ugly on this site. After giving my students a few new chapters in their textbook and getting their CDs burned yesterday, I finally had a little bit of time to turn my attention to fixing up my site a bit.

I ended up choosing just plain old blue for my link hover color. But, once I start fixing things, it’s hard to stop. As soon as I settled on blue for my links, I started getting irritated by other usability problems. For one, there were forty comments on my post about SEO. Most of them were from people, but a lot of comments were also just trackbacks from other people linking to the site. It was kind of hard for me to follow the discussion thread and read through them. In other words it was time to edit my comments.php and see what could be done.

Here’s what I came up with:

  1. Comments are now numbered.
  2. Comments made by me are now light blue, #eef, to be precise.
  3. I’m not quite sure what the difference between a trackback and a pingback is, but they’re pink now.
  4. All other comments still alternate between normal (#eec) and lighter (#ffd) shades.

Now, it’s easy to tell refer to comments by number, it’s clear which of them are from the me and which are from guests, and it’s easy to skip over trackbacks and pingbacks while reading a thread. I’m pretty happy with it, but feedback and suggestions about the layout are more than welcome.

For those curious about how I did it, I’ve posted the code below: continue reading…

WordPress 2.1 is out, and I’ve just installed it. It’s actually a much bigger update than I had realized. Here are the biggest changes I’ve noticed:

  • The visual editor is far better than it was before. You can also tab back and forth between the WYSIWYG editor and the code very easily.
  • There’s a spell checker built into the editor. For users of Firefox 2.0, this is superfluous, but for those living in the dark ages and still using IE, it’s a useful feature.
  • WP 2.1 autosaves drafts regularly.
  • Users can now arbitrarily chose any page to be their home page, and display a list of their posts on any other page. I personally spent hours figuring out how to code around the lack of this feature several months ago. Now, it’s easy.

This upgrade is a “must have”.  With it, WP is now more useful as a CMS than ever before. The full list of features is at

I’ve been thinking about making a static home page for for quite a while. According to my site traffic logs, most of the visitors to this site are new visitors who come in through search engines as opposed to regular readers. I suspect that most people who stumble across this site have come looking for specific information, and probably aren’t interested in the majority of what I blog about. Not only that, but I wouldn’t be surprised if a large number of them weren’t really sure what a blog is.
continue reading…

In my second coding job, I was as a web programmer at a start-up broadband ISP in 1999. Admittedly, it was a pretty messed up company. Still it’s pretty depressing to be this inept at using wordpress. I spent 3 hours messing around trying to get my new site’s colors to match the old’s. It was maddening. It was as if wordpress simply ignores CSS. I’d change the background-color of some or another block in my styles.css file, and reload my blog to see that NOTHING had changed. I then hunted around in vain, looking through all the other files which I thought might be over-riding my settings: the page template, the main template, and the post template. It turns out that the background colors set in the style sheet of the default wordpress theme, are all over-ridden by background graphics. In what file were all of them placed, you might ask? The header.php file, of course. That’s exactly where you put background images to be loaded across a whole page IF YOU’RE TRYING TO “WEED OUT” THE “WEAK” USERS!

I’ve been sick since Sunday, and haven’t had much to do except work on migrating my blog. Still, I’m not too happy having wasted my moments of relative clarity between fitful half-fevered naps figuring out somebody else’s non-intuitive page layout system.

Well, now that I have a debit card again, I’ve registered a domain, and I’m in the process of migrating everything to wordpress. First I tried Andy Skelton’s excellent tool, but it didn’t handle the Chinese text in my blog too well.

WordPress database error: [Illegal mix of collations (utf8_unicode_ci,IMPLICIT) and (latin1_swedish_ci,COERCIBLE) for operation '='] SELECT ID,post_date,post_title FROM wp_posts WHERE post_date='2005-11-30 23:43:00' AND post_title='[Movies] å�?'左走å�?'å�?³èµ° Turn Left Turn Right' LIMIT 1

It turns out that by default, MySql uses latin1_swedish_ci settings for collation_server as well as some other variables. Not too surprising I guess, since MySQL AB was founded by two Swedes and a Finn.

Fortunately, I’ve got everything working now. After my migration is done, my main blog will be at, and have greatly improved categories support among other things. Here’s what my blog looks like with the default wordpress theme:

a picture of my blog