Archive for the 'Design Considerations' Category

Arrays of Objects and __get: Friends Forever

In PHP, an object is always passed around as a reference, which allows one to deal with objects in a very transparent manner, since the only way to deal with a by-value copy instead of the real deal is to explicitly use the clone operator. Recently, I came upon a situation in which it was […]

Monday, January 11th, 2010

Javascript Abuse #2,463,981: Centering Content

Another quick rant/post about the wonderful world of abusing javascript. Consider the following code: function moveScreen() { var myWidth = 0, myHeight = 0; if (typeof(window.innerWidth) == ‘number’) { //Non-IE myWidth = window.innerWidth; myHeight = window.innerHeight; } else if (document.documentElement && (document.documentElement.clientWidth || document.documentElement.clientHeight)) { //IE 6+ in ‘standards compliant mode’ myWidth = document.documentElement.clientWidth; myHeight […]

Thursday, September 24th, 2009

CSS Versus Tables: The War Continues

Unfortunately, there’s a very ugly side to this debate. If you’ve actively been on either side of it, then you might hold the opinion that there is no pretty side to the debate, but in a relative sense, there is. The pretty side is about vertical alignment issues, low resolution displays, and the trauma of floats gone wrong. The ugly side is, without question, the unholiest member of the family that is CSS-supporting (however loosely the term need be applied) browsers: IE 6.

Thursday, July 23rd, 2009