May 13, 2010
Media & Publishing
Android’s strength is cellular voice and data transfer and its low power consumption while Chrome OS has better support for various hardware architectures, and they are both based on the Linux kernel.
If you were to build a tablet that has a touch screen not bigger than 9 inches and a modern browser as its only application, GSM + data connection, instant startup and a batter life of 12 hours, which OS would you choose?
I can’t understand why Google needs Chrome OS. Is it only for devices that don’t have touchscreens?
#
May 5, 2010
Web Design
Let’s have a site wide version number that is changed every time something is updated and cache needs to be invalidated. This number is stored in a simple text file. Cache keys are made up of Request-URI and this unique key, which is passed around in a cookie VERSION_NO.
On every page request javascript calls version.php?timestamp (which is never cached because of the timestamp), which using stat() reads the last modified timestamp of that text file and compares it to the value of VERSION_NO cookie. If they are different, a new cookie value is set, which in turn changes the cache key for all future requests, and the cache is invalidated.
The only thing I don’t know is how fast and resource hungry is the stat() call?
Update: or would it be better to use filemtime()? There is a comment which says that 1000 filemtime() calls take 0.0049 seconds, which I think is very reasonable.
#
May 5, 2010
Web
You can like something and there is nothing you have to do about it. It is an effortless act and there are no explanations required or expected. And people actually don’t care for what you like. They are interested in what you care for, because caring isn’t pointless, it means you take a stand.
#
May 2, 2010
WordPress
Here is a quick way to clear APC opcode cache with a single click within your WordPress dashboard Read more »
#
Apr 28, 2010
Web Design, WordPress
This server uses PHP 5.3 with PHP-FPM (FastCGI Process Manager) patch and APC opcode cache. Several minutes after activating APC, I noticed that some pages stopped loading. Turns out it was because of an APC timebomb bug which is when all cache writes got locked because of expiring cache entries and new writes happening at the same time. The temporary solution is to add apc.slam_defense = 0 and apc.write_lock = 1 in php.ini.
#
Apr 22, 2010
Meta
Excuse the mess while I’m moving away from MediaTemple. It feels so good to be home in Latvia on a speedy VPS.
There is a handy little WordPress feature that I had not used before:
define('RELOCATE', true);
which allows you to set up a temporary domain name while your new name server records are spreading across the internets. For example, if you changed the NS record for example.com, you could use new.otherdomain.com to access the site you’re moving. Normally WordPress would try to redirect you to example.com (which is it’s site_url).
#
Apr 6, 2010

ST-131 launch on April 6th, 2010
STS-131 is now in the orbit (view on map). There is a live video stream available from the mission control in Houston.
I spent many hours watching these videos from their preparation for this mission. Amazing people and phenomenal work.
#
Apr 5, 2010
WordPress

Select images for each gallery
I have updated the Multiple Galleries plugin to work with WordPress 2.9 and also 3.0-beta1. Another good news is that the plugin is now in the official repository. Those of you who are already using the very first version of this plugin will get an automatic notification that there is an update available. How lovely.
#
Mar 22, 2010
Random Musings

[Y]ou can’t ascribe great cosmic significance to a simple earthly event. Coincidence — that’s all anything ever is. Nothing more than coincidence. [...] There are no miracles. There is no such thing as fate. Nothing is meant to be.
— (500) Days of Summer
#