Section 1 HTML5 Tag Structure
The core to all web design is Hypertext Markup Language (HTML), the code that sits behind every web page and allows users to create stunning web sites. Todayâs web sites can do amazing things. Can you imagine not being able to use solutions such as Googleâs Gmail, Microsoftâs Bing, or view content on YouTube? Web sites have moved from static pages to complex applications. The core HTML language requires more and more functionality to meet our needs. To this end, a new standard has been introducedâHMTL5.
Where HTML Code Can Be Found
Not sure how to find HTML? It can be located on any web page by right-clicking your mouse and selecting View Page Source, as shown in Figure 1.1.
How the HTML code is presented will depend on your web browser. No matter what you are doing on the Webâdeveloping a Personal Home Page (PHP) shopping cart, implementing an ASP.NET application, updating your latest blog entry, or playing an online gameâevery solution on the Web must use HTML at some point. If not, then your web browser will not be able to display the page correctly.
Figure 1.1 HTML code can be viewed in any web browser. Here, Googleâs Chrome is color coding the HTML code.
The Evolution of the Web
Back in the days of 1995 when the Web was just gaining mainstream attention, it was assumed that you needed a computer (preferably running the Windows 95 operating system) running Microsoftâs Internet Explorer (IE) to view the Web. Yes, you could also use Netscapeâs Navigator, but Microsoft took care of that problem by 1999. There was not much of a change to this model for about ten years.
The change to the desktop PC Internet browsing model began with the easy installation and adoption of wireless networks. A bulky computer, or even a laptop, to connect online was no longer needed; rather, users only needed a device that had enough power to go online and get what they needed, wherever they were.
The first few Internet-powered devices were crude at best, but it did not take long for mobile devices to catch up with PCs. The change came with Appleâs release of the iPhone and iPad, which both support one of the most advanced web browsers. Appleâs mobile devices shipped running a mobile version of their web browser called Safari. Does âmobile versionâ mean that features were cut from the full Mac OS X version? In a word: no. Mobile Safari is built using an open-source web browser called WebKit. Apple makes the bold claim that their iPhone web browser displays web pages exactly the same way as a full browser running on a Windows PC. Indeed, to add insult to injury, Apple took the boast even further: The iPhone web browser supports much of the latest core web technologies that Microsoftâs Internet Explorer does not support. Namely, the iPhone, back in 2007, was already supporting HTML5, and Microsoft was a long way from this support (Figure 1.2).
Microsoft has taken the emergence of HTML5 very seriously. Internet Explorer 8 was terrible, but Internet Explorer 9 was a lightning bolt of change. IE9 is not your typical web browser. The support for HTML5 is very credible, and with IE10 just around the corner, the complete embrace of HTML5 technologies is almost complete.
Figure 1.2 The iPhoneâs mobile Safari already boasts strong support for HTML5 technologies.
Today, we assume that most devices will connect to the Internet. It is not just the realm of the PCâgame systems, Blu-ray DVDs, MP3 players, cameras, storage SD flash cards, and more devices connect to the Internet every day. HTML, this core language that runs how we view the Web, is changing to support a post-PC world that connects to the Internet.
The Rocky Road from HTML4 to HTML5
Tim Berners-Lee developed HTML in 1989. The Internet has been around since the 1950s, but it had a fundamental flawâ connecting from one disconnected source to another was very difficult. Tim Berners-Lee addressed this issue by creating two technologies:
- HTTP, the Hypertext Transfer Protocol, a service protocol to enable web servers to run
- HTML, the Hypertext Markup Language, a scripting language to allow the presentation of text with embedded links to documents on the same server or a different server.
The revolutionary spin on Berners-Leeâs HTML language is that the link embedded in the page did not need to know if the web page it was linking to existed. If the page did not exist, then you received an error. If the page did exist, then you jumped from one web site to another.
A second reason for the success of HTML is that the language is very easy to learn and use. HTML uses a simple concept of tags that start and end a section. For instance, the following will show as a block of text when viewed through a web browser:
The tag concept for writing web pages is easy to learn and use. Needless to say, the World Wide Web really caught on. By the early 1990s it was becoming clear that the Web, in particular HTML, was going to be a very big thing. At that time a fortunate event happened: Tim Berners-Lee decided not to cash in on the success of the Web and instead formed a coalition to standardize popular web technologies. This group, called the World Wide Web Consortium (W3C; www.w3c.org) is an open standards body made up of representatives from many different companies such as Apple, Microsoft, Adobe, Sun, Google, Real Networks, Oracle, IBM, and many more. A goal of the W3C is to prevent any one company from forcing a technology onto users. This is important, as Microsoft was effectively trying to do this as they dominated the Web from 1997 to 2007.
The W3C has produced many popular technologies used by software companies each and every day. These include HTML, Extensible Markup Language (XML), Web Services Protocol (SOAP), and the Portable Network Graphics (PNG) format, among many others. Each of these standards was proposed, defined, ratified, and published with group approval. One of the first sets of standards to go through this process was HTML.
Berners-Leeâs first version of HTML is very different from the version we use today. For instance, Berners-Lee did not care for design and did not include any way to format text in the first release of HTML. Images were also an afte...