Software

Screen Saver Option Disabled on Windows 7/XP

For unknown reason, my machines would suddenly disable their screen saver options (e.g. with the "on resume, display log on screen" check box grayed out). Whenever this happens, it would trigger the security alert and I will get a warning from the IT department to fix the issue.

I am tired of having to hunting down the answer every time and therefore I am recording it here.

The following method is what usually works for me.

1. Go to "Start" type in "regedit"

2. Go to

[HKEY_CURRENT_USER\Software\Policies\Microsoft\Windows\Control Panel\Desktop]

Delete the "ScreenSaverIsSecure" value.

Quick Fix: Windows XP Crashes with Blue Screen with Video Content

For some reason, my main working machine, a Windows XP desktop, recently  started to crash a lot followed by the blue screen of death. The error message output at the blue screen does not seem to be helpful.

***STOP: 0x0000008E (0xE0000001, 0xBA490925, 0xA880D820, 0x00000000)
***watchdog.sys - Address BA490925, base at BA90000, Date stamp 480254ab

Display LaTeX Math on Drupal with MathJax

MathJax seems to be the emerging standard for displaying math on the Web at this moment. It is supported by American Mathematical Society and American Physical Society, and has already been adopted by major math related discussion venues such as Physics Forums and Stack Exchange. MathJax displays math using CSS and Web fonts instead of images, so the quality is very high and is resize-friendly. Below are some examples:

Inline math: the geometric product $\boldsymbol{uv}$ of vectors $\boldsymbol{u}$ and $\boldsymbol{v}$ is $\boldsymbol{u}\cdot\boldsymbol{v} + \boldsymbol{u}\wedge\boldsymbol{v}$, where $\boldsymbol{u}\cdot\boldsymbol{v}$ is the inner product and $\boldsymbol{u}\wedge\boldsymbol{v}$ is the outer product.

Upgrade Drupal with Almost Zero Down Time

This site was setup in 2007 with Drupal 5, and it has not been upgraded until today. I did not feel the need to upgrade since this is just a personal blog. A few days ago I wanted to install a module, but Drupal version 6 is required, so I thought it's finally the time to upgrade Drupal. This Drupal upgrade tutorial suggests to first take down the site to upgrade, but I do not like that. It turns out that more than a few days of work are required to bring back a fully functional upgraded site, so taking the site down to upgrade is not a good idea. Below is what I did to upgrade this site from version 5.3 to 6.22 with almost zero down time (well, maybe a few seconds, I didn't time it). Continue reading »

How to Share Mouse and Keyboard across Machines

If you have multiple machines but only one set of mouse and keyboard, then you must check out this neat little tool called Synergy. It allows you to seamlessly share mouse and keyboard across machines. It even allows you to copy and paste text across machines.

Fix Drupal Search

Today I tried to search "clojure" using the search box at the top right corner, but could not find anything. I know I wrote a few posts on Clojure recently, so there must be something wrong with the search functionality here. This is a Drupal site, and this should be an easy fix. Indeed, I quickly figured out the problem and solved it.Here is what Idid. Continue reading »

How to load context of text files into DB2

The task is fairly simply --- I need to load the content of some text files into DB2. There are many ways to do so, but since I only need to this only once (hopefully), I want to find an easy way without writing any external code.

So here is the solution:

(1) create a table containing a CLOB (VARCHAR should work as well, if we know the maxium size of the files in advance) column. For example:

create table test (docid INTEGER GENERATED BY DEFAULT AS IDENTITY,doc CLOB)

A Simple GTD List Solution: Desktop, Web and Possibly Mobile

I have been searching for a lightweight list solution since I started trying out the Getting Things Done (GTD) approach a few days ago. Unlike calendar events, list items (projects and actions) do not associate with a particular time and date, therefore, using a calender for them is not appropriate. According to David Allen, for lists, we should "just go for simplicity, speed, and fun". Here I operationalize that into these properties:

  • Simple, but can still do these:
    • Handle lists for "project", "next-action", "waiting-for" and "maybe"*
    • Be able to tag an item with "context", and organize items by context
    • Support sub-list

Editing Web Textarea with Desktop Editor

Nowadays we do a lot of text input on the Web, like posting on forums, filling out a support request form, commenting on someone's blog, etc. Although Web forms often offer a variety of so-called rich text editing capabilities, nothing beats the good old desktop editors. For a vim person, a plain Web textarea simply is not the place for text editing. Fortunately, for Firefox users, this pain can be eased. There are a few Firefox addons that allow people to use external editors for editing textarea. Continue reading »

Syndicate content
Nice place