HTML5: What is it and How Does it Work?
Here we will learn about HTML5, its advantages, and how it differs from Flash, Silverlight and other web development platforms that it has either replaced already or is poised to do so going forward. So without further ado, let’s dive right in and learn why most web developers prefer HTML5, who maintains it and why it is recommended by the World Wide Web Consortium (W3C).
What is HTML5?
HTML5 is a programming language and the latest public-facing iteration of HyperText Markup Language, or HTML, created in 1989 by the inventor of the World Wide Web, Sir Tim Berners Lee. Recommended by the WWW Consortium (W3C), it is used for structuring and presenting content on the web and is maintained by a consortium of the major browser vendors, including Apple, Google, Mozilla and Microsoft. Together, they form the Web Hypertext Application Technology Working Group (WHATWG), which now has the sole authority over the HTML and DOM (Document Object Model) standards after W3C ceded control last year.
The WHATWG’s HTML ‘Living Standard’, which is continually upgraded, is now authoritative, replacing the static, snapshot-based standard propagated by the W3C earlier. The two have often been at odds with each other, most notably about the permissible content of the element, which was a major source of contention between the two organizations, with the W3C definition allowing a broader range of uses than the WHATWG definition. However, they have been working together over the past several years to develop a unified HTML5 standard across the web.
How Does HTML5 Work?
HTML5 includes all 3 basic web design components – HTML, CSS and JavaScript. While HTML is used to create text on a web page, CSS is used for the styling and to indicate how elements on a webpage will be presented. As for JavaScript, it is responsible for user activity and action on a webpage. Using these elements, developers can create responsive webpages that can automatically rearrange all elements to fit the screen of desktops, laptops and mobiles, irrespective of their size, resolution and aspect ratio.
What Technologies Has it Replaced?
HTML5 was first released in a public-facing form in 2008, with a major update in October 2014. It was intended to replace not only HTML4 (originally standardized in 1997) but also XHTML 1 and DOM Level 2 HTML. However, given its versatility and ease-of-development, W3C, which was developing XHTML 2.0 as a competing platform, stopped working on it and recommended HTML5 as the future of web development. From the user side, the biggest change from HTML4 is that we no longer need plugins like Adobe Flash or Microsoft Silverlight to play videos on different websites. Remember how a decade ago you were often prompted to ‘Update Flash’ (or Silverlight) while trying to play videos online? When was the last time you saw such a prompt? And when was the last time you needed to update Java on your computer? Chances are, you haven’t seen such messages in the last five years.
If you are still seeing such prompts, you need to stop visiting those sites because they’re either old, out-of-date sites that pose a security risk or are fake sites run by scammers trying to install malware on your system. As of September 2020, fewer than 0.035% of sites used Silverlight, 2.5% used Adobe Flash, and less than 0.017% used Java, making them pretty much redundant in the modern web built around HTML5.
What Are the Advantages of HTML5?
There are many reasons why HTML5 has become the preferred web development platform. Not only is it easier to code in than other markup languages, but it also includes built-in rich multimedia features that ensure no other software or browser plugin is required to design a complete website from scratch. The technology allows web designers to develop all types of applications, animations and other multimedia features that run on a browser. Another massive reason for the uptake of HTML5 is the fact that it isn’t proprietary, which means you don’t have to pay royalties to use it. It’s also a platform-agnostic technology that can be used to render websites on Windows PCs, Linux machines, MacBooks, Android, iPhones, smart TVs and more. All you need a compliant user agent (any of the popular modern browsers), and you can have access to all the goodies available on the web at your fingertips.
What’s more, HTML5 also enables developers to use advanced features such as GPS, camera and accelerometer in their web apps, making it best suited for today’s ‘mobile-first’ era. It has also made it easier to add discussion boards, drag-and-drop tools, chat platforms and a host of other elements into websites. Another massive advantage of HTML5 is that it allows developers to easily port applications to mobile. Now that every browser ships with native support for the standard, it has also largely replaced legacy platforms like Flash and Silverlight, thereby improving security and offering a seamless browsing experience.
What Are the Disadvantages of HTML5?
In spite of its near-ubiquity, HTML5 comes with its own set of problems that trouble both programmers and end users alike. Primary among them is the lack of a standard HTML5 video format, but there are also other issues that remain a problem in what is otherwise the most reliable, secured and feature-rich web development platform. Here are some of the disadvantages of HTML5:
1. No Standard Video Support for all Browsers
One of the major issues with HTML5 is the confusion regarding video format support for different browsers. Even though all modern browsers incorporated HTML5 support several years ago, not everybody supports all HTML5 video formats. There’s often been confusion about which browser supports which video format, because that depends on not only the user agent, but also the platform (Windows, Android, Linux, etc). Among the main formats, H.264 has become the de facto standard, with all browsers supporting it on all platforms. Ogg Theora is also supported by all browsers on all platforms except Safari on iOS, while VP8/WebM is also supported by everything, although, Safari requires manual installation. There’s also a similar issue with audio, although, WAV (PCM) and MP3 (MPEG) are supported by all the major browsers.
2. HTML5 ‘Living Standard’ is Always Evolving
It also doesn’t help that the ‘Living Standard‘ makes HTML a moving target for web developers who often have to second guess about support for new features. While some consider the continual upgrades to be an advantage, unexpected changes in the standard can render elements in a website useless until the admin issues a fix. In reality, this rarely happens with up-to-date sites, but it’s still an issue that keeps web designers on tenterhooks.
3. Gaming with JavaScript
Another major hurdle is gaming support because the only scripting language supported by HTML5, JavaScript, is a less-than-ideal platform for a strong gaming experience. Custom name spaces, member access, interfaces, and inheritance, have problems under JavaScript, forcing developers to look for workarounds. That said, game developers have still moved from Flash to HTML5 because of seamless cross-platform support across all user-agents.
HTML5 Browser Support
As mentioned earlier, all modern browsers, including Edge, Firefox, Chrome, Safari and Opera, support at least some elements of HTML5 on all platforms. However, their support for the standard doesn’t manifest itself identically. As a rule of thumb, Firefox supports the widest range of HTML5 features, with Chrome following closely behind.
Here’s a (non-exhaustive) list of the browsers that support HTML5:
Microsoft Edge Mozilla Firefox Google Chrome Apple Safari Opera Opera Mobile Android Browser Chromium Konqueror GNOME Web
You can check out CanIuse.com for a detailed breakup of what’s supported by which version of which browser on what platform.
HTML5: The Present and Future of Web Development
HTML5 improves the way the web works, making it easier for developers to create great websites and for users to experience those creations irrespective of their device of choice or the browser they are using. It is the biggest and most popular web-development platform, and with its ever-evolving standards incorporating new features and functionalities, it’s likely to stay that way in the foreseeable future.