Mac versus PC. It’s a tired debate. People on both sides get really worked up over their preferred computing platform and the vitriol flies. The latest argument is over the cost of laptops, spurred on by Microsoft’s Laptop Hunter ads. Microsoft is gaining a lot of traction with these ads, particularly in these tough times. And according to Redmond, Apple is wetting their pants in fear (take with pillar of salt).
I’m not going to debate this point, PC’s can be cheaper (note how I didn’t say less expensive). And if upfront cost is the only factor, then buy a PC. But, you should know what you are getting with your budget friendly machine.
There is a great deal of competition in the PC world and profit margins are razor thin. PC’s are essentially a commodity market. If a PC maker earns a meager profit on the hardware, they consider themselves lucky. In this environment, two decisions are made that dramatically impact the experience you get from your low cost PC.
First, they often opt for cheaper components which come with a higher rate of failure. For you, this means downtime. Instead of surfing the Web for kittens having comical misadventures, you will be boxing your machine up to send it back to the manufacturer. But no big deal, PC’s are cheap. Just go buy another one to use while yours is in the shop.
Second, they are riddled with malicious ads. No, I’m not talking about the mine field that the internet has become for unsuspecting PC users. I’m talking about the other decision by PC makers in their quest for profit. Trial software.
PC makers take kickbacks from software companies in return for preinstalling trial editions on the machine. So, the first thing you see when you power up your new computer is essentially ads. Fine. Not such a big deal. Except that when you go to uninstall all of these software ads, you realize that they are as hard as some of the worst viruses to remove. It’s such a pain that there is now a market for software that cleans your brand new machine of all of this junk. And don’t think that won’t turn into the same cat-and-mouse game that anti-virus software is now.
In order to get a clean machine, you either have to buy some software to clean it off, or spend your valuable time learning how to rid your PC of these infectious trial versions. But your time isn’t that valuable, right? And you saved all that money over buying a Mac. Take that, Apple!
Of course, you can buy a PC built with quality parts and free of trial editions. But those PC’s are at the same price level as Macs. So, if you don’t have the time or energy for budget computing, consider an honest comparison of features instead of cheap theatrics.
CSS Conditional Comments
In the war on CSS hacks versus IE conditional comments, we’ve always fought on the side of conditional comments and felt good about it. But there has always been one thing that made me jealous of our counterparts on the CSS hack side of the field—having the necessary IE styles in the same place as all the rest. So I did something about it.
Over at GitHub, I have posted a new project called CSS Single File. And what it does is allow you to use IE conditionals in CSS comments. It parses your CSS file(s) looking for comments that looks like this:
div#page{ width: 940px; padding: 20px; /* if lte IE 7 width: 960px; */ }It collects them all, indexing by IE conditional, and spits out the necessary HTML IE conditional comments for you. Currently, it only renders IE specific styles in embedded style tags but it could easily be upgraded to handle file rendering and caching. The real question is whether this approach is worth pursuing with the need for these hacks on their, albeit incredibly slow, way out the door.
What becomes a more interesting question, however, is what if instead of rendering IE conditional comments in the HEAD of your HTML document, the parser incorporated browser sniffing and rendered the IE styles right there in the CSS file. And if you are doing browser sniffing to filter styles, why not any browser conditional comments. Think about it.
div.some-box{ border: solid 1px #555; /* if FF 3 -moz-border-radius: 5px; */ /* if Safari 3 -webkit-border-radius: 5px; */ }Does this approach allow us to deliver exactly the CSS that the particular user needs and target browser specific features and bugs without sacrificing validation? Or does it just encourage bad behavior? Does it make our CSS files more or less readable?
In his highly revered Web tome, QuirksMode, Peter-Paul Koch writes on the topic of conditional comments:
Of course, he meant that is was impossible to do this using native browser behavior. And, he is just talking about IE. But IE is not the only browser with buggy CSS rendering. And in the age of High Performance Websites when we are already running our CSS source files through a parser to compress them, why can’t we add a feature to make our lives easier while we are at it?