Omer Zak's Computer Related Itches Page


One of the advantages of Open Source Software is that if anything itches you, you can develop, or pay someone else - like me - to develop something to scratch your itch.

In this page you'll find links to some little things which I developed to scratch my own itches.

Maybe you'll find here something useful for you, too.

Scratching a bookmarks itch in Mozilla

(Was written at 2006 January 07 by Omer Zak)

This tip may or may not be relevant for FireFox or more recent versions of Mozilla.

I have a long, hierarchical and mostly unsorted list of bookmarks used by my installation of the Mozilla 1.7.8 browser. The browser provides a search box, which allows me to locate a bookmark using textual matching.

However, if I want to add a new bookmark and have to find the appropriate folder to which add it, the search box is useless for this purpose. Even if it finds me other bookmarks filed in the right folder (based upon their subject), it does not show me in which folder those bookmarks are.

The following hack solves the problem. The directory names are correct for Debian Sarge. If you use another Linux distribution or another OS, YMMV.

Look for the bookmarks.html file in your ~/.mozilla directory, load it (as a regular HTML file) in your browser, and bookmark it!

Its URL will typically be: file:///home/yourusername/.mozilla/default/something.slt/bookmarks.html

Next time you need to search for the folder where to add a new bookmark, load the bookmarked bookmarks.html file and run standard text search (Edit/Find in this page; usually bound to CTRL-F).

Then you can happily add your new bookmark to the best folder for your purposes.

Helping your friend start a Web site

(Was written at 2006 January 07 by Omer Zak)

Suppose you have unused disk space in your Web hosting service. You have a friend, who wants to start a Web site, while spending as little money up front as possible. Or you want to serve different Web sites using several domains, while consolidating the disk space being used in a single area to save some Web hosting fees.

Some Web hosting services allow you to add, without additional cost, additional domain names to their name servers - as long as they point at the same root directory in your disk space.

Sometimes you want all those domain names to serve the same content (such as when you register the same domain under, .com, .biz, etc.). However, sometimes you want some domain names to serve different content (such as when you are doing your friend a favor).

Sometimes you want to serve files written in Hebrew to visitors who browse, and in English to visitors, who browse

It is possible to configure your Web hosting service's Web server to serve up different content, depending upon the domain name used to browse your Web site, if you put in your Web site's root directory a .htaccess file with the following contents:

RewriteEngine on
RewriteCond %{HTTP_HOST} ^(www\.)?friendlydomainone\.com$
RewriteRule ^(index.html)?$ [R,L]
RewriteCond %{HTTP_HOST} ^(www\.)?friendlydomaintwo\.com$
RewriteRule ^(index.html)?$ [R,L]

Of course, you have to modify the domain names to fit your specific circumstances. Your friend needs to put his Web site files in a subdirectory of the Web site root directory. If he uses scripts, he needs to coordinate with you the use of those scripts.

(DISCLAIMER: the above works for Apache version 1.3.29 configured with the appropriate permissions.)