July 2008
What the heck is a HTML? Web enabling technology for the uninitiated
Posted by: Aidan on 3 Jul 2008 @ 10:13 am Category: Programming and Coding for the Web
So, you know about the web and use it frequently... but you're interested in knowing more about how it all works. Where do you begin?
Well, there is a multitude of different technologies, all woven together by various individuals to create something that is useful (or in some cases just pure time wasting fun). In this post, I will attempt to explain some of the technologies that allow you to play with this marvelous thing we call the world wide web. I suspect this will be broken up into several posts, as there's just too much for me to rattle off in one go... you'd probably just fall asleep trying to read it all!
OK, so you have probably noticed that when you want to go to a particular website, you type the address into your browser, and away you go. It seems simple, but there's actually a few things going in the background that aren't immediately apparent. The main one being that your computer, and the computers that make up the internet, don't actually know where you want to go when you type in www.ireckon.com. It's nice for us humans to be able to identify sites by name, but the computers need something a little more abstract (i.e. being the big calculators they are, they much prefer to work with numbers). Enter DNS. DNS stands for "Domain Name System", and basically it allows the computer to translate our human readable address into more computer friendly IP addresses. You've likely seen IP addresses before, they look kind of like this: 192.168.1.1. DNS isn't so much specific to the web, as it is to networks in general, but it plays such a major role in allowing you to get things done on the web, I thought it's worth a mention.
Next we have HTTP - Hyper Text Transport Protocol. This is the protocol, or 'language', used by your computer to download information (such as images and the pages themselves) from a server. After you computer has determined the IP address of the server it wants to talk to via DNS, it establishes a connection to the server and uses HTTP to ask the server for the page you want to see. The server uses this same connection to send the information back to you. For most web pages, you computer will make several HTTP requests - one for the main page layout, and then one for each file referenced by the layout (i.e. images and other media). When you computer receives this information, it begins rendering it on the screen.
HTML & CSS - Hyper Text Markup Language & Cascading Style Sheets. These are the primary languages used to define the way in which a page is displayed (i.e. the layout). Like in the previous cases, these languages are used mainly by humans to tell the computer specifically what they want. The HTML & CSS code by itself doesn't look anything like the pages they describe, but your web browser knows how to read it like instructions on how to paint a picture. One problem with this is that different web browsers interpret HTML & CSS code in slightly different way, and the end result may end up looking different when viewed in certain web-browsers. This forces web designers and developers to test their pages/applications across the full spectrum of web-browsers and operating systems, which of course takes time. There are standards bodies which define the rules by which HTML & CSS should be written and interpreted, but implementation of these rules is still the domain of the people who create web-browsers, and they don't always agree with the standards bodies - thus we're left in a situation where extra effort must be made to have web pages and applications work consistently on all web-browsers. The situation is better now than it has been in the past, but there's still a lot of room for improvement by the web browser vendors. I'll be a happy chap when the day comes where I can create a page in standards compliant HTML & CSS, and not have to worry about making sure it works in all browsers, because they all work in the exact way the standards bodies set forth. The worst offender for non-compliance to HTML & CSS standards is Internet Explorer (made by Microsoft), but nearly all major browsers (Firefox, Opera, Safari, Konqueror, etc) are guilty of flouting the standards in some way or another. Many parties will be thrown by people who work on the web when this situation is resolved. Many wild and crazy parties.
There are a lot of other technologies that enable a rich web browsing experience, which I will attempt to cover in a future post. For now I hope the above descriptions shed some light on the mysterious workings of the Internet and the web.



