blog · git · desktop · images · contact & privacy · gopher

Simplification, Relaunch


This web site and its blog was launched in 2006. Some of the code in the backend is even older. Worse than that, it’s PHP. Some years ago, I started simplifying things and removed the MySQL database (there was a time when everything needed to have a MySQL backend …). Nonetheless, I wasn’t happy with the result. Everything was still pretty ugly, the code was complex, it was old and rotting.

Time for a relaunch.

I don’t like meta postings, so I’ll tell you a little bit about the details behind the new web site.

New design

I’m not referring to the “visual design” or CSS, but the backend of the blog. How are the files laid out? What code is run?

First of all, there is no server side code anymore. None. While I was at it, I also switched from Apache to lighttpd. I now write blog postings, or rather all the pages, on my computer. This reminds me of how we used to make web sites many, many years ago: Using Frontpage on Windows. You create your page, test it locally in your browser, and then upload the HTML files to your web server. This is not wrong per se. Why not preprocess data locally if viable?

Of course, I don’t want to write HTML manually. This is just annoying. Let alone maintaining index files and tables of contents. There has to be some kind of automization.

On my hard drive, files are laid out like this:

├── 2006-05-13/
│   └── 0/
│       ├──
│       └──
├── 2006-05-16/
│   └── 0/
│       └──
├── 2006-06-14/
│   └── 0/
│       ├──
│       ├── xp_sec_empty_tcpview.jpg
│       └── xp_sec.jpg

There’s a directory for each day and additional sub directories because it might happen that I write several articles on one day. By looking at the JPEG files, you can derive one important principle: Each blog posting should be a self-contained entity. Everything that belongs to it shall reside in the same directory. Gone are the days where everything is scattered or even buried in MySQL tables. It’s all neat and compact.

Dead giveaway: “de” and “en” tell you that the blog is now bilingual. More on that below.

Another important thing: “.md”. Everything is now written in Markdown – not only the blog postings, but also all other pages. That’s very comfortable. Raw Markdown can be read and written easily, that’s a nice property. There’s almost no obscure syntax elements. I even thought about not using any HTML at all, let the web server deliver Markdown directly. Well, I dropped that idea, because hyperlinks are a good thing and they’re even better when you can click on them.

Now, for converting Markdown into HTML, I use a little python script which is build upon the “markdown” library. I don’t run this script directly but a set of additional shell scripts. Essentially, they iterate over all “*.md” files. They also create index files – which are generated in Markdown, too. Turning them into HTML is an additional step.

Everything is a lot simpler than it was before. This has a cost. For example, there is no “search” function anymore, nor is there a direct way for people to comment on my articles. However, while migrating data, I kept important comments and simply appended them to the blog postings. You see, the fact that there’s no direct way of commenting doesn’t mean that I don’t want people to comment. So, I invite you to visit the Contact page and write me an e-mail if you have something to say. :-)

My thumbnail script is also gone. It was used to generate thumbnails on the fly, directly on the server. I don’t think that’s a big loss. For now, I’ve simply linked images. That’s totally fine.

English is the main language

I tend to think that nobody reads my blog. From time to time, though, I get feedback. Sometimes, even people from foreign contries contact me. The last one to do so was Yu-Jie Lin. The only way he could read my articles was by using Google Translate. I tried that myself and had a good laugh. Doesn’t work very well. Nevertheless, he got a rough idea of what’s going on here.

My old PHP code was simply not capable of dealing with multiple languages. Now I can do that. As you can see above, there’s a “” as well as a “”. My wrapper scripts create two distinct index files from these source files and we’re done.

I decided to use English as the main language for this web site. Only the blog still exists in a german version. Sure, you can reach more people when writing in English. However, German is my mother tongue, I grew up with it, I use it every day, and I think in German. I like writing in that language. It’s easier and I’m much more fluent. Nonetheless, English is important and I have to try to use it as much as possible. It’s training. This doesn’t even have anything to do with this blog. Using English, getting better at it, that’s incentive enough. :-)

Feeds are available in both languages, too. The old feed URLs are no longer valid, but, for the time being, I installed some redirections.

Data migration

Back in the day when the term “blog” wasn’t really around – at least not where I live –, I reused some PHP code that I’ve written earlier for a web forum. It was pretty close to BBCode. More than half of my postings was written using this nasty markup language. Later on, I switched to writing HTML manually. Well, kind of. It’s just so tedious, so I added some more “macros” and “short cuts”.

Result: Over 200 blog postings using custom markup languages, with no converter in sight. Worse, back then, I used elements like “bold”, “underline” or “font-size” in places where “h2” would have been the appropriate tag. So, even if there was a converter, I still would have had to post-process all files manually.

I had no choice but to convert each posting manully from some custom markup language to Markdown. This took three weeks but I believe it was worth it. Markdown is widely used and supported, for example by projects like pandoc.

While doing this migration, I once more realized how fragile the world wide web is. Everybody keeps telling, “the internet does not forget!” Maybe. But hyperlinks are completely volatile. If you don’t check them every day, they’re broken sooner or later. Maybe about 80% of hyperlinks in my older articles don’t work anymore. With this in mind, I don’t feel too bad that I myself broke all my links while doing this relaunch.

Furthermore, a lot of content is simply obsolete. It doesn’t matter anymore. Software changes, operating systems change – everything changes. Many articles are only interesting for the sake of nostalgia or for historical purposes. I even thought about aborting my migration. Maybe I should just start from scratch? Well, I couldn’t do it. I just wanted to keep my stuff alive.


Well, there’s no real conclusion. Let’s just see how long it takes until the next relaunch.