Monthly Archives: May 2015

Firefox: how to enable the built-in tracking protection

Just read an article on BBC News that starts of with the AdBlock Plus team winning another case in a German court (yeay) and ended with a report on how Firefox also has built-in tracking protection which -for now- is off by default and is somewhat hidden. To enable it, just open about:config and set privacy.trackingprotection.enabled to true. I disabled Ghostery for now, let’s see how how things go from here.

Autoptimize: video tutorial en Espanõl!

The team contacted me a couple of days ago to let me know they created a small tutorial on the installation & basic configuration of Autoptimize, including this video of the process;

Mejora la velocidad y el SEO de tu sitio web comprimiendo ficheros JavaScript, CSS y HTML

Watch this video on YouTube.

The slowdown noticed when activating JS optimization is due to the relative cost of aggregating & minifying the JS. To avoid this overhead for each request, implementing a page caching solution (e.g. HyperCache plugin or a Varnish-based solution) is warmly recommended.

Muchas gracias Webempresa!

Music from Our Tube: Daniel Lanois going drum&bass

As usual I heard this on KCRW earlier today; Daniel Lanois leaving his  roots-oriented songwriting for some pretty spaced-out instrumentals with a jazz-like and sometime straight drum & bass feel to them. This is “Opera”, live;

Daniel Lanois – "Opera"

Watch this video on YouTube.

You can watch, listen & enjoy more live “flesh & machine”-material in this live set on KCRW.

Instant Pages vs Instant Web?

Again an interesting ALA-article about web performance (or the lack thereoff), triggered by Facebook’s “Instant Articles” announcement;

I think we do have to be better at weighing the cost of what we design, and be honest with ourselves, our clients, and our users about what’s driving those decisions. This might be the toughest part to figure out, because it requires us to question our design decisions at every point. Is this something our users will actually appreciate? Is it appropriate? Or is it there to wow someone (ourselves, our client, our peers, awards juries) and show them how talented and brilliant we are?

This exercise clearly starts at the design-phase, because thinking about performance in development or testing-phase is simply too late.

Is your string zipped?

While looking into a strange issue on a multisite WordPress installation which optimized the pages of the main but not of the sub-blogs, I needed code to check whether a string was gzipped or not. I found this like-a-boss code-snippet on StackOverflow which worked for gzencoded strings:

$is_gzip = 0 === mb_strpos($mystery_string , "\x1f" . "\x8b" . "\x08");

But this does not work for strings compressed with gzcompress or gzdeflate, which don’t have the GZIP header data, so in the end I came up with this less funky function which somewhat brutally simply tries to gzuncompress and gzinflate the string:

function isGzipped($in) {
  if (mb_strpos($in , "\x1f" . "\x8b" . "\x08")===0) {
    return true;
  } else if (@gzuncompress($in)!==false) {
    return true;
  } else if (@gzinflate($in)!==false) {
    return true;
  } else {
    return false;

Klunky, but it works. Now if only this would confirm my “educated guess” that the original problem was due to a compressed string.