Quick URLs for some pages

January 18, 2004
0 comments This site

Supposing I want to send someone a URL to one of the pages of my site. Then if the URL is too long it gets complicated. In emails there's the risk that the long URL gets broken up on many lines. And on SMS there's too much typing. So I've introduced Quick URLs.

For example: https://www.peterbe.com/photos/misc/balloon-flying/ballong_skog_eld.jpg/view becomes https://www.peterbe.com/q-004 Much easier to type in when sending a text, isn't it.

I have to manually select every URL that I want to do this too, but this might change with time. When you enter a Quick URL like the one above you get redirected to the real URL.

Ugliest site of the month

January 17, 2004
0 comments Web development

...or how to gain insanity points.

See if you can count the number of text styles (different colours, weight, style, position) on this page

And they have the nerve to write:

"This page last updated Jan 07, 2004 ~ For best interactive experience use Microsoft's Internet Explorer 5 and up."

China, being trained in prosecution by Sweden

January 16, 2004
0 comments Sweden, Politics

"China vows to increase prosecution cooperation with Sweden [...] on prosecution practice and prosecutors training"

Wow! Talk about Yin-Yang. China, with the highest capital punishment ratio in the world; Sweden, where you get looked up for 5 years (3,5 if good behaviour) for the same crime. And! In Sweden they probably have uncensored broadband access in the cells. (was that a joke?)

Now these two countries are working together. I've never studied law, but I guess "prosecution" is more the process of court-work to prison etc. Not so much crime-law and prison sentence.

All together I think this is good news. China needs to reconsider much of its crime and punishment policies. The flattering news for the Swedes is that it's China who is changing, with Sweden as its mentor. Not the other way around.

"Bodstrom [Thomas Bodström, Sweden's Justice Minister] said that China has undergone tremendous changes in its judicial field since the country's reform started about two decades ago."

BUT! This news site, Xinhuanet is probably government controlled and biased and I haven't seen anything about this on DN.se (liberal, one of Swedens biggest newspapers) yet.

Lost In Translation

January 16, 2004
0 comments Film

Lost In Translation Lost In Translation is a beautiful little film about an American man and a woman, alone and misery in Tokoyo. He's an old movie celebrity. She is the wife of a fashionable photographer. They are both very lonely and are desperate to go back to America again. They don't know a word of Japanese and the Japanese don't know a word of English. Well, they know some but when they speak they mix up the r's and the l's. "Have a nice fright", "lip the stockings" they say.

There they are. Lonely at the hotel they're staying in and after some time they become friends and start to enjoy themselves. Their happiness isn't show by their words or actions. It's instead shown by how they enjoy Tokoyo.

With time they become better and better friends. Just on the verge of being romantic. He's much older than her and they're both married but somewhat uncertain of their marriages. It's kind of like forbidden love, still not like some many other cheesie movies. They kind of love that was acted out in this film is very rare in movies.

I really like Bill Murray who plays the leading role with Scarlett Johansson. There's lots of good humour throughout the film.

A returning joke is the language barrier. Something that I personally feel resemblance with from when I moved to France.

You should definitely try to go and see this film. I recommend it. Here's the page IMDB.com

Pholph's Scrabble Generator

January 16, 2004
1 comment Misc. links

I've actually never played scrabble, but when I was a kid (in Sweden) we played something called "Alfapet" which was like scrabble but without scores. This little cute web app calculates your name's scrabble score. Silly, isn't it?

My score was 19

So vivid dreams I couldn't get out!

January 15, 2004
0 comments Wondering

Today I took a little nap after breakfast. Actually I lied down to read and fell asleep. The interesting thing is that I got trapped in my own dream. Twice!

I woke up, walked to the kitchen, met the cleaning lady who comes in once every two weeks. Had a quick chat with her but she didn't at all look like Maureen. Ah well, I thought, I'm still dreaming. Cute.

Then I got up and switched of the music on my computer by stopping on WinAmp, but nothing happened! So I turned down the volume completely on the loudspeaker, still nothing happened!

Now I got worried. I'm still dreaming and I don't want to do so. How do I get out? I started slapping my face with both hands and shake my head and shortly I felt my consciousness taking over again. When I woke up I was hyped with fear and odd thoughts of what had happened.

This has never happened before, so it's worth writing about on my website :)

Recon - Regular Expression Test Console

January 14, 2004
0 comments Python

This is a fantastic little Python GUI using Tkinter, for testing your regular expressions in Python. You first paste or write in some text, then you doodle some regular expressions to see the outcome. What I do miss is exporting of actual code. Usually when I write my regular expression I fire up the interactive shell from which I can copy code when I'm happy with it. Like this:


>>> import re
>>> e=re.compile(r'\?q=(.*?)&', re.I)
>>> print e.findall("http://www.google.com.br/search?q=paper+plane&hl=pt-BR")
['paper+plane']

From silly code like that I can actually copy and paste the actual syntax. Ah well, I still like this Recon thing.

Crontab wizard

January 13, 2004
2 comments Linux

This little nifty web application lets you create crontab syntax through a nice a interface. I'm quite a beginner with crontabs so I think I'll hold on to this URL.

I've recent discovered pycron which is a free crontab gui for windows written in Python

About page finally written

January 13, 2004
0 comments This site

This is my first attempt on trying to describe some of the technical mechanisms of this site. I will try to keep it updated as I change the website.

Hopefully I will also write a little something about me, myself and I when time allows.