Browser Standards: HTML5 Test – Best Results

Since the number of the available browser is constantly growing, it becomes every day more important to adhere to international standards. Until the last year, every developer was interested about how much a browser supported the XHTML 1.0 or 1.1 specifications and the CSS 1.0 or 2.0 specifications.

Nowadays things have changed a little bit. We are entering a new dynamic era of internet browsing. Browsers will be even more capable of serving and displaying media contents. Doing what? Correctly implementing the HTML 5 standard and the CSS 3.0 specifications.


To help developers in the understanding and/or evaluation of the behavior of a browser, Niels Leenheer has written the HTML5Test web page. This page uses a little bit of Javascript to trick your browser with common HTML 5 implementation test cases, and collects all data in a really clean report. I suggest you to try that page now with your current browser, just to get an idea.

This test gives each browser a score, based on how many HTML 5 elements or features can handle correctly. The max score a browser can reach is 300, plus some additional bonus points for not-strictly-necessary features.

I gathered some results for the main web browsers, in the chart you can see below. I tried to use the more recent version for each browser. Just to get an appetizer of what will be next, I also tried a beta/alpha/nightly version of each of them.

Leggi tutto →

Loggable: a simple log4j meta-library – Part 2

In a recent post I described the goal of my Loggable meta-library. If you haven’t read it yet, I suggest you to do it now.

What we are going to do now is analysing the second main component of the meta-library, the centralized controller Log.

How does it work

The main responsibility of the Log class is handling the logic behind the creation and returning of the Logger instance that the caller class should use. This logic, as we’ve already seen, is driven by the @Loggable annotation.

The Log class will have a single point of access: the public static method get().

Leggi tutto →

Loggable: a simple log4j meta-library – Part 1

If you work in a J2EE environment, you surely have (or at least will have) used the standard Apache log4j library almost once. This powerful and configurable logging library is commonly used throughout whole enterprise projects, for many reasons: debugging, testing, exception logging, tracing, application profiling, et cetera.

In this article I want to explain a meta-library that I am currently writing to allow a more decentralized control of the log4j library methods and an easier log-calls implementation throught your entire application: convention over configuration. This is my motto.

Leggi tutto →

How to sort rated content

If you are a web developer, or at least a webmaster, and if you have rateable content on your website, you probably almost once faced this common problem: how should I sort my content, using the collected rating data?

As a common problem, it has common but different solutions, most of which are wrong. We will analyse two cases: the up/down rating, and the 5-star rating.

Leggi tutto →

Mastering the Ackermann Function

Yesterday I came in touch with a curious, astonishing mathematical function. It’s called Ackermann function.

Mathematically speaking, it is a well-defined total function. That is, it has defined values for every integer input (= total function), and this value is not ambiguous (every input has one and one only possible output value) (= well-defined).

Speaking about computer science, this function is computable, but it’s not a primitive recursive function. In other words, you can implement an algorithm to express the function using while-loops (= computable), but still you cannot write an equivalent algorithm using only do-loops (= not primitive recursive). I suggest you to try this statement.

Leggi tutto →