I’ve programmed in a couple languages, but I’ve never gotten the hang of any of them. I’ve experimented with PHP, Java, a little bit of C+…they’re all so damn confusing. Sure, I learned how to use Java some (I took an actual class on it), but the syntax was just weird. I’m sure it made sense to someone at Sun Microsystems, but to the rest of us, it’s just messed up.
I came across an xkcd comic involving Python, so I decided to take a look. I’ve only done a couple of tutorials, but from what I’ve seen, Python is insanely simple. Yes, it has its own syntax, but it’s not nearly confusing as Java. For instance, take a look at the ways you print “Hello world” in both languages:
print 'Hello world'
What’s even more, that Java snippet is useless without a class surrounding it. The Python code can run just like that (assuming you have a Python interpreter and have made the file executable). No curly brackets, no semicolons, no compiling. I’m definitely going to look more into this programming language. At least until I finally find the drawback. There has to be a drawback to a language this simple. I shall find it and then make witty comments about it to embarrass Python programmers! Excellent.
There are quite a few browsers out there, but they are, for the most part, pretty much the same. The only major differences are in their rendering engines, that is, the code that allows them to display web pages. The most popular one is Gecko, which is used by Firefox, Mozilla, and Netscape. Another is Presto, used by Opera. Finally, there is Trident, the layout engine used by Internet Explorer. Of course there are others, but this isn’t a post about layout engines. You’ve got Wikipedia for that.
Anyways, the rendering (or layout) engine of a browser determines how HTML and CSS are displayed. Most browsers display things similarly, but not Internet Explorer. IE has always been the black sheep of the browser family, preferring proprietary functions (such as ActiveX) to standards. Of course, no browser is completely standards-compliant, but IE is as far off as it can get. The most recent version, IE7, has solved quite a few problems, especially with CSS, but it can still be a hassle to code a website that will work perfectly in all browsers. The problem is that IE is still the most used browser. If your site doesn’t work in IE, you’re going to have a lot of people who will steer clear of it.
The answer? Well, you could just eliminate anything in your site that’s causing problems with IE. Or, you could let web surfers know about Firefox. Chances are that the only reason most people are still using IE is that they don’t know about any alternatives. Read on to see an easy way to let IE users know they should switch to Firefox while allowing non-IE users to continue on with no trouble.
Continue reading ‘Browser sniffing’