Archive for the ‘HTML’ Category

Introduction to CSS3



Introduction to CSS3

W3C Working Draft, 23 May 2001

This version:

Latest version:

Previous version:


Eric A. Meyer

Bert Bos (W3C)

and software
rules apply.


The members of the CSS&FP Working Group have decided to modularize the
CSS specification. This modularization will help to clarify the relationships
between the different parts of the specification, and reduce the size of the
complete document. It will also allow us to build specific tests on a per
module basis and will help implementors in deciding which portions of CSS to
support. Furthermore, the modular nature of the specification will make it
possible for individual modules to be updated as needed, thus allowing for a
more flexible and timely evolution of the specification as a whole.

This document lists all the modules to be contained in the future CSS3

Status of this document

This is an official introduction, issued by the CSS Working Group, which
details the modularization of the CSS3 specification and the CSS test suite.
This document should be considered to be informative, not normative. See the
Style overview pages for more information on W3C’s work
on style sheets, including CSS.

This is a public W3C Working Draft for review by W3C members and other
interested parties. As a draft document, it may be updated, replaced, or
obsoleted by other documents at any time. It is inappropriate to use W3C
Working Drafts as reference material or to cite them as other than “work in

A list of current W3C Recommendations and other technical documents
including Working Drafts and Notes can be found at

Please send comments to the
mailing list (see how to
) or to the editor.

Table of contents

1. Why Modules?

As the popularity of CSS grows, so does interest in making additions to
the specification. Rather than attempting to shove dozens of updates into a
single monolithic specification, it will be much easier and more efficient to
be able to update individual pieces of the specification. Modules will enable
CSS to be updated in a more timely and precise fashion, thus allowing for a
more flexible and timely evolution of the specification as a whole.

For resource constrained devices, it may be impractical to support all of
CSS. For example, an aural browser may be concerned only with aural styles,
whereas a visual browser may care nothing for aural styles. In such cases, a
user agent may implement a subset of CSS. Subsets of CSS are limited to
combining selected CSS modules, and once a module has been chosen, all of its
features must be supported.

2. Module Overview

All modules contain a “Conformance: Requirements and Recommendations”
section. Any module whose table row is backed with green is considered part
of the “CSS Core.” The listed deadlines (backed in red) represent the time at
which a module should be ready for Working Draft publication. There are also
columns which indicate a module’s participation in each of three “profiles”:
HTML Basic, CSS3, and SVG. A module without any indicated module
participation is at risk of being dropped from CSS3 before it reaches
Proposed Recommendation status. A module without a listed editor is backed in
yellow, and is in serious danger of being dropped.

Module Editor(s) HTML
Syntax / grammar / etc. X X
Selectors Tantek Çelik, Daniel Glazman, Ian Hickson X X 5 Oct 2000 26 Jan 2001 1 Mar 2001
Values, Units Håkon Lie, Chris Lilley X X
Value assignment / cascade / inheritance Håkon Lie X X
Box model / vertical Bert Bos X X
Positioning Bert Bos X
Color / gamma / color profiles Tantek Çelik, Chris Lilley X X 22 Jun 1999 5 Mar 2001
Background Tim Boland X X
Line box model Eric Meyer X X
Text / bidi / vertical alignment Chris Lilley, Michel Suignard X X 17 May 2001
Ruby Michel Suignard X 16 Feb 2001
Font properties Chris Lilley, Michel Suignard X X
WebFonts Chris Lilley X
Generated content / markers Håkon Lie X
Replaced content Eric Meyer X
Paged media Steve Zilles X 28 Sep 1999
User interface Tantek Çelik X 16 Sep 1999 16 Feb 2000
Tables Bert Bos X X
Columns Håkon Lie X 22 Jun 1999 18 Jan 2001
SVG Chris Lilley X X
Math Angel Diaz
BECSS Michel Suignard 4 Aug 1999
Media queries Håkon W. Lie X 4 Apr
17 May
SMIL Debbie Newman
Test Suite Eric Meyer X

3. Module Descriptions and Related

3.1. Introduction

This provides a general overview of the specification’s goals, as well as
basic notes on how CSS works, acknowledgments, and so forth.

  • 1. About the CSS2 Specification
  • 2. Introduction to CSS2

3.2. Syntax / grammar

A way to attach arbitrary properties to a hierarchically structured
document or other data structure, with the characteristic that it has
built-in “forward-compatibility” (a.k.a. “extensibility”).

3.3. Selectors

Describes the selectors of CSS3. Selectors are used to select elements in
an HTML or XML document, in order to attach (style) properties to them. The
draft includes the selectors of CSS1 and CSS2 and extends them with new
proposals that allow, for example, elements to be selected based on whether
they contain a certain word, or whether they are the only element of their

3.4. Values & units

Things which are applied to values.

3.5. Value assignment / cascade /

How properties interact, and the core of how CSS operates.

3.6. Box model / vertical

The box model describes the basics of the normal text flow, including how
to “float” blocks of text or images, but excluding columns, tables, and other
advanced layouts; i.e., it describes how text and other objects are strung
into lines, and lines into blocks (paragraphs), and how those blocks are put
below each other or side by side with the help of margins and borders. It
treats both horizontal text and vertical writing modes.

3.7. Positioning

This describes the process of placing an element someplace other than it
would normally be in the normal flow of the document.

3.8. Color / gamma / color profiles

In general, basic color descriptions and color handling in multiple
environments. The color profiles section describes how two properties can be
attached to embedded images to specify their “color space,” which is the
information a renderer needs to paint the right color for each pixel. It
should do away with the annoying problem that images, especially GIF and
JPEG, but sometimes also PNG, look different on a Mac than on a PC, or other

3.9. Colors and Backgrounds

A description of how element foregrounds and backgrounds are formatted.

3.10. Line box model

A description of the line box model for inline elements, and the inline
content of block elements.

3.11. Text

Description of the handling of text in user agents. Includes bidi,
vertical alignment, text decoration, line breaking, etc.

3.12. Fonts

Description of the handling of fonts in user agents.

3.13. Ruby

A draft that contains proposals for new style properties for typographic
traditions that have so far had little attention in CSS, such as vertical
Japanese and Arabic. The CSS working group is cooperating with W3C’s
Internationalization working group on this.

  • The Internationalization CSS WD

3.14. Generated content /

A description of how content is generated and markers are displayed.

3.15. Replaced content

A module explaining how replaced content is handled and what qualifies as
replaced content.

  • ???

3.16. Paged media

Extends the properties that CSS2 already had with new ones to control such
things as running headers and footers, page numbers and print-style
cross-references (“see page…”).

  • 13. Paged media
  • The CSS3 Page WD
  • Running headers and footers
  • Cross-references
  • Float : gutter-side/fore-edge-side
  • Floating boxes to top/bottom of page

3.17. User interface

Contains features for styling some interactive, dynamic aspects of Web
pages: the look of form elements in their various states, more cursors and
colors to describe GUIs (graphical user interfaces) that blend well with the
user’s desktop environment, and a proposal for “kiosk” mode.

3.18. WebFonts

Authors continue to clamor for “more control” over their pages, and the
fonts used in presenting them. This module will attempt to provide a way to
make fonts more Web-friendly.

3.19. ACSS

An attempt to make styled content even more accessible.

3.20. SMIL

An attempt to link CSS and SMIL together.

3.21. Tables

The tables module contains the properties to lay out boxes in rows and
columns. It allows a designer to assign roles like “table,” “cell,” “row,” or
“caption” to boxes and provides for various alignments and border styles.

3.22. Columns

Proposes new properties to create flexible column layouts.

3.23. SVG

A format that expresses shapes (lines, circles, splines, etc.) in an
XML-based language and their style (fill color, stroke width, etc.) in CSS.
This should make it easy to create text and graphics in the same style simply
by using a single style sheet for both. SVG uses several existing CSS
properties, but also introduces new ones that may or may not be useful for
styling text. It will progress to Recommendation as a separate specification,
but the (new) CSS properties are coordinated with the CSS working group.

3.24. Math

An attempt to provide style properties for mathematical expressions. This
will obviously be deeply linked to the MathML specification.

3.25. BECSS

A proposal to use the CSS syntax and CSS’s system of cascading and
inheritance to attach “behavior” (rather than style) to elements. Behavior in
this context refers to any dynamic changes to the style or the document in
response to user events, such as clicks and key presses. The behaviors
themselves are expressed as pieces of script, in languages such as

3.26. Media queries

To describe in more detail what type of devices a style sheet applies to,
this document proposes media queries. A media query consists of a media type
and one or more expressions to limit the scope of a certain style sheet.
Among the proposed media features that can be used in expressions are
“width”, “height” (size of the display), and “color” (color depth of the

3.27. Test Suite

Providing implementation guidelines, concrete examples, and user insight
into implementation support, a test suite is crucial to the success of any
specification. Although the Test Suite is a module in itself and has a module
owner, individual module owners are responsible for assisting in the creation
and review of tests for their specific module.

4. Appendices

Some appendices will be split up to go with individual modules. These are:

  • Appendix B. Changes from CSS1
  • Appendix E. References
  • Appendix F. Property index

For example, the changes between one version of a module and another
should be tracked in an appendix to that module, not a single appendix to the
entire specification. Similarly, there should be a property reference for
each module. There may be a single cumulative reference for the entire
specification, although this is not yet known with any certainty. Each module
should also include an appendix listing any dependencies on other modules or

There will also be a few specification-wide appendices. There are
projected to be:

  • Appendix A. A sample style sheet for HTML 4.0
  • Appendix H. Index

5. Module template

All modules should conform to the format defined in the CSS3 editing
[member-only link]. In addition to the definitions of properties
and values, each module contains a list of dependencies on other modules or
specifications, and also provides a list of changes from CSS2.

Categories: HTML, News, Resource Tags: , ,

Hollywood – Web 2.0 Style

 Hollywood - Web 2.0 Style

In no particular order, comparing companies and dotcoms to Hollywood counterparts:

YahooNicole Kidman
At some point in time, not too long ago, Nicole Kidman was a name-brand. Having her name and face on the posters meant you’d have a solid blockbuster that everyone went to see, from horny boys to horny housewives. She was married to Tom Cruise, men wanted her more than any Playboy playmate, and women wanted to be her. Somewhere along the lines, she became yesterday’s news, she married a country pop star (still dont get that one), and now she spends her time being overpaid to be in B-horror movies like Invasion and The Others. I dunno why, but when I think of Yahoo!, I think of Nicole Kidman.

Oprah has many many many fans who love her unconditionally, they will swear up and down that Oprah can do no wrong. Yet, she also has many haters who think she dumbing down America, and is just plain rude to Dr. Phil. Love her or hate her, you gotta admit, the girl’s got POWER. Oprah tells you she likes a book, it becomes a best-seller for the next 22 weeks. Oprah says she stopped eating meat because of Mad Cow Disease, the next thing you know, the Texas cattle industry sued her, claiming her simple WORDs cost them $12 Million! (it’s true, look it up) Oprah has been praised as one of the best and richest entertainers in America, cover story after cover story, and she came from humble roots and built herself into the mega-star that she is today. Google, give us your “O” face!

Wal-MartTom Cruise
Tom Cruise is a scientologist, people think he’s gay, people think his marriage to Katie Holmes is all for show, they think he is a weirdo, a freak, the anti-christ, who knows. But one thing you know is, the man is a huge movie star. So, America, you tell me—if you think Tom Cruise doesn’t deserve to be a mega movie star, why do you keep going to see his movies? The same can be said for our megastore, Wal-Mart. Everyone claims they don’t want to support them, they are doing evil things in order to get those super low prices, and yet, lo and behold, people are still flocking to Wal-Mart, dat after day. Tom Cruise sells movie tickets, Wal-Mart sells everything else.

YoutubeScarlett Johanssen
Scarlett is the latest “IT” girl. She has a great rack, a great body, and claims no cosmetic surgery. She also moved her way up the movie ladder QUITE quickly. Methinks there was some extra-curricular activities to get her those sought-after roles, but hey who can hate her, she’s freakin Scarlett Jo! Youtube is much the same. It’s fun, easy, everyone instantly is amazed by it and quickly loves it. Also, it plays a lot of good music. I wonder if I can type in a song on Scarlett Johanssen’s breasts and see the new Killers video. Next time I see her, I’ll give it a try.

FriendsterChristina Applegate (Kelly Bundy)
The original TV bleached blonde, Kelly Bundy showed America being a slut was cool and funny. Sure, she was slow, sure she was poor, but hey, you wanted her, because there wasn’t anyone else who did the same stuff for free. Same can be said for Friendster. It was slow, the functions weren’t all that great, but hey, my friends were on it, and so I wanted to be on it. That is, until the next Social Networking slut came walking by.

MySpacePamela Anderson
Oh Miss Pam Anderson, you were so popular for a while. I mean, sure people still talk about you now, but mostly to refer to your former self. At one point you were the hottest of the hot, every magazine, you had like 3 tv shows, but now you are just a joke. No one wants to be near you, and anyone who was near you claims they never were. Myspace is now that old whore.

FacebookLindsay Lohan
Miss Lohan, you took the dumb blonde attitude, added some red hair and bigger tits, and voila, Slut 3.0. Just be well aware, that your 15 minutes of fame are up pretty soon…especially since you can’t sell any movie tickets without a Disney logo attached to it. Facebook, you may have gotten your Microsoft bailout to legitimize your current social network reign, but I can assure you Myspace felt the SAME way about 12 months ago. So, keep at it, but watch your back, before the door hits you on the way out.

DiggAmy Winehouse
Amy Winehouse is like queen of the trainwrecks. How do simultaneously have a number one selling record and single (a song about not going to rehab) and yet, on a DAILY basis, you let down all of your fans by becoming piss drunk and stoned before every concert, sing horribly, get photographed with coke dripping out of your nose, and claim it is all because of your drug-addicted husband who is locked away in jail on drug charges. Amy Winehouse is slipping into a downward spiral of madness, and everyone is watching and feeling sorry for her, but at the same time, she does it to herself. Digg is the same trainwreck, imploding on itself, when it could have sold out at an earlier time and made itself a better and bigger Digg. Amy Winehouse has turned into a caricature of herself where most people are talking about her messups rather than her music, and the same goes for Digg.

PayByTouchBritney Spears
Probably the Queen of the 2007 trainwrecks, Britney was just amazing. I won’t even go into the details, because I’m sure all the super cool bloggers have gone into it all, but she was just unbelievable to watch. Pay By Touch achieved the same trainwreck greatness this year. I mean, the things that happened in regards to both Miss Spears and Pay By Touch were jaw-dropping. Bravo to both of you, I have been more entertained this year by both breakdowns more than I have by each of you, since both of your inceptions.

TechCrunchAdam Sandler
Adam Sandler is a funny guy, I’ll give chim that. But when in the world did he become a blockbuster movie guy? Why would people pay good money to see him play a retarded water boy? Why remake Mr. Deeds? Why? How did he become a movie star? Same to you, Mr. Arrington. How, when, and why did anyone start taking whatever you said about startups as gold? Did anyone bother to look at your track record? This I will never understand.

ValleyWagPerez Hilton
I know, I know, it’s too easy of a comparison. But as a longtime PerezHilton reader, I’ve gotta say Valleywag had the exact same effect on me, but BETTER. After the first Perez post that I read, I was hooked on his random writing and more random drawing on pictures. After randomly finding a Valleywag post when doing research on a company I was looking up, I fell in love with it. I check it regularly, from home, at work, on my iPhone. I just wish they posted even more! It’s just the perfect mesh of gossip and technology. Good stuff!

TechnoratiJessica Simpson
Girl, you is yesterday’s news, at one point in time everyone loved you more than anything, now they wouldn’t wipe their arse with you. The same goes for Jessica Simpson. Nuff said.

PowerSetParis Hilton
How did Paris Hilton get famous? Does she have a talent? Can she do anything besides look hot and say: “I look hot”? I mean, seriously, why did people spend day after day after day talking about her, hyping her up, her4 perfumes, her stupid reality show, her clothing line, her crappy movie roles. For some reason, people talk about PowerSet almost as much as they do about Hilton. What’s funny is that with all the lack of talent she has, she has still managed to do more to impress me than PowerSet has. I’ve got my fingers crossed that PowerSet comes out with a sex video. That will really push it to the top.

FirefoxJudd Apatow
Ever since Freaks and Geeks, Judd Apatow has garnered a cult following. He introduced characters on tv and in the movies that were so relatable, that sometimes you would be watching his movies and feeling like you remember that exact thing happening to you. He always had critical acclaim, yet his tv shows got cancelled. And then, starting with 40 Year Old Virgin, then Knocked Up, and more recently Superbad, Apatow got BOTH the critical acclaim and sold those movie tickets. He was the guy everyone loved to root for, and Firefox is the browser everyone loves to root for. It’s gaining momentum and soon enough it shall become the successful version of Judd Apatow instead of the Freaks and Geeks-Undecided version of Apatow.

Madonna seems to have been around since Microsoft has, and just like Microsoft, Madonna constantly tries to reinvent her image. Every album has her trying new things, and yet, her fans will always like her best for her classic stuff. Sure, she gets some props here and there for her techno albums or her forray into country music mixed with funk mixed with whatever you want to call it. But, when it comes down to it, Madonna’s fans love her for her old music, and they will support her even with her new crappy albums. Same goes for Microsoft. Sure, you’ve got a lot of different products and services, but when it comes down to it, your fans are all about Windows (except Vista–blech!), and Office. We can’t live without Windows XP, MS Word, MS Excel, or Outlook….or can we? Here’s to seeing Madonna’s new album sell more copies than Windows Vista. (it will definitely have less in-store returns)

AppleHoward Stern
Howard Stern has always said what he wanted and did what he wanted. He spent years living in oscurity because his radio shock jock shtick was just not ready for prime time. But then, somewhere along the line, the bubble burst, and he had hundreds of thousands of fans, almost overnight. He did things people wished he could do. And his listeners were listening longer than any other DJ’s listeners would listen. His hardcore fans will swear up and down that he has always been the greatest since sliced bread. And his haters listen to his shows just to hear what he has to say next. I think Apple, much like Stern, has followers who love them, and followers who are following just so they can catch Apple when it slips up. Law of averages says it will happen, but who knows how soon. In the meantime, keep climbing the charts, and keep focus on not listening to the naysayers, just listen to your fans.

LinuxEllen Degeneres
The Linux penguin is funny, and it would probably dance if it had Happy Feet. Ellen is funny, and she always likes to dance and has happy feet. Bur seriously, like Ellen, Linux seems to be a nice alternative to all the shock schtick of the other 2 major OSes. Linux just wants to be simple and stable, without all the flash, and Ellen took that same route to reach her stardom. Of course, it took her many many years of her “nice” routine to really get noticed and have a major level of fans, but if that penguin just keeps at it, I’m sure it will, too.

iPhoneAngelina Jolie
Those lips! Those eyes! Those tits! Those legs! That ass! Men and women across the globe can all agree that Angelina Jolie is a thing of perfection, seemingly coming from another planet to blow us away by her sexy bod. Forget about her acting, she is just gorgeous to watch. Sure, she can’t really act, doesn’t make much of a believable action star, and her personal life is pretty crazy, but as soon as she steps into a room, or onto a magazine cover, the music stops and everyone loves to stare. Much like her, the iPhone garners as much love for its beauty and functionality. Sure, the phone service may not be the best,
the email is a little spotty, the Edge network is like molasses, but oh it is so damn sexy! The video quality! That screen! That auto-correct typing! The flipping of music albums with your fingers! I can honestly say that sometimes it’s a coin toss when it comes to fingering my iPhone or fingering Angelina Jolie.

Okay, so the RIAA is like: “Hey man, dont steal music, the musicians need the money to feed their families!” and the MPAA is like: “Dont steal movies, thats like killing people and then eating their rotting corpses!” I’m like: “If you made music cheaper than $10 a cd and movies cheaper than $10 a movie, then maybe I wouldn’t steal so much because I have about 700 albums and about 100 DVDs. Jeez!” Eh, who am I kidding, as long as free music is available, I’ll have to keep on getting it.

CybersourceQuaker Oats Guy
Quaker Oats guy tells everyone: “Well, this is the right thing to do, and the right way to do it.” Well, I got news for your Quaker guy, many many many many people eat things OTHER than Quaker Oats, and they seem to be having great lives. Heck, they may even say Quaker Oats SUCKS. Deal with it. Same for you, Cybersource. You think you have the best gateway, the best screening, the best everything? I don’t think so. I think you are just as out of touch with the reality of online merchants as the old man who talks about Quaker Oats. Besides, I like Farrina much better.

ViacomCharleton Heston
The old man who claims he knows best…Viacom is telling everyone else what to think. Screw them. Screw Heston. And down with guns! You damn dirty apes!!

AdbriteCarrot Top
Seriously, Adbrite just sounds like Carrot Top. Somehow Carrot Top performs worldwide, and somehow Adbrite gets gigs, too.

VonageRosie O’Donnell
Rosie O’Donnell—annoying! Vonage—Annoying! Rosie O’Donnell: “Oh, wah wah wah, this isn’t fair” Vonage: “No, please don’t sue, wah wah wah” Vonage, you get what you deserve because you spent $25 Million a month getting that “Whoo-Whoo Whoo-whoo-whoo” song stuck in my head! And Rosie, you’ve always been the poor-man’s Roseanne Barr, and now you are gonna end up just like she is.

CnetRoger Ebert
He may be old, but we still rely on good old Roger Ebert to give us the skinny (no pun intended) on what he thinks of the movie. Sure, he usually doesn’t match what the typical American would think about when watching a movie, but I think we all listen to him simply because of the fact we all know he has seen MANY MANY movies. Hell, we have the movie reviews to prove it. Same goes for Cnet. I dunno if people actually rely on their reviews to decide on a product, but we’re all pretty sure when a new product comes out, Cnet will be reviewing it. And so we flock to their reviews just to see what they thought.

WikipediaSteven Spielberg
Oh Spielberg. This guy is like Hollywood’s golden director. Almost everything he does, is a blockbuster. And almost everything he does, is critically acclaimed. Hollywood can always rely on him to do something with grace, with pizzaz. Spielberg is like everyone’s favorite person to love: critics, fans, and people within the industry love him. Wikipedia is like everyone’s favorite website to love. Users, bloggers, techies, everyone loves Wiki. (hey that could be a tv show, Everyone Loves Wiki, okay fine maybe just a webisode)

AmazonTom Hanks
Oh, Tom Hanks is like Hollywood’s golden child. Everyone loves him because he doesn’t attempt to be flashy or special or anything other than Mr. Guy Next Door. And that is what Amazon is all about. They want to be your familiar online shopping, nothing too flashy, just simple, easy, you know what you will get with every purchase. And, like Tom Hanks, every year, Amazon continue to out-do their last year in sales. You go, boyees!

First Data CorporationRupert Murdoch
People don’t seem to realize, but Rupert Murdoch has got his nails dug deep into a LOT of media. Much like him, First Data is touching many many pennies across many many transactions. He and First Data are the 800 pound gorillas. Which one of them wants a banana?

Categories: HTML, News, Web 2.0

Web 2.0 Design Process

Web 2.0 Design Process

Categories: HTML, News, Resource, Web 2.0

Color palette inspiration: web design “brillante”

Color palette inspiration: web design “brillante”

Avevo confessato in un precedente post (Color palette inspiration: l’autunno) di essere entrata nel tunnel della creazione di palette di colori. Poco dopo, infatti, ho pensato fosse il caso iscrivermi a COLOURlovers, almeno per avere un posto in cui salvare di volta in volta quelle – a mio parere, ovviamente – ben riuscite e cestinare le altre e anche per rendere immediatamente disponibile il download in diversi formati.

Alcune tra quelle già inserite (l’ultima, blue freshness, l’ho aggiunta proprio stamattina) sono dedicate al web design.

Pubblico sul blog, per prime, quelle pensate per la realizzazione di siti dai colori brillanti e ad alto contrasto tra loro (in stile 2.0, per intenderci… e per ora ancora ci intendiamo, in attesa che il presagio di morte che rimbalza in rete si concretizzi), anche per esaudire la richiesta di alcuni lettori che erano alla ricerca di palette dai colori molto vivaci.

Forse è superfluo specificarlo, ma è chiaro che la scelta della combinazione di colori da utilizzare non è mai un’operazione puramente estetica ma fortemente connessa alla tipologia di sito web. Buona norma sarebbe conciliare uso estetico e uso comunicativo dei colori, senza perdere di vista l’importanza della coerenza, cromatica ma anche relativa al rapporto tra la combinazione scelta e gli obiettivi (comunicativi, strategici e connessi al brand) della presenza sul web. Ma questo molti di voi lo sanno meglio di me.

no nature #1

no nature #2

no nature #3

no nature #4

green freshness

blue freshness

Web 2.0 … The Machine is Us/ing Us

Categories: HTML, News, Web 2.0

HTML 5 differences from HTML 4


HTML 5 defines the fifth major revision of the core language of the World Wide Web, HTML. “HTML 5 differences from HTML 4” describes the differences between HTML 4 and HTML 5 and provides some of the rationale for the changes. This document may not provide accurate information as the HTML 5 specification is still in development. When in doubt, always check the HTML 5 specification itself. [HTML5]

Status of this Document

This section describes the status of this document at the time of its publication. Other documents may supersede this document. A list of current W3C publications and the latest revision of this technical report can be found in the W3C technical reports index at

This document is the first working draft of “HTML 5 Differences from HTML 4” produced by the HTML Working Group, part of the HTML Activity. The Working Group intends to publish this document as a Working Group Note. The working group is working on a new version of HTML not yet published under TR. In the meantime, you can access the HTML 5 Editors draft. The appropriate forum for comments is, a mailing list with a public archive.

Publication as a Working Group Note does not imply endorsement by the W3C Membership. This is a draft document and may be updated, replaced or obsoleted by other documents at any time. It is inappropriate to cite this document as other than work in progress.

This document was produced by a group operating under the 5 February 2004 W3C Patent Policy. W3C maintains a public list of any patent disclosures made in connection with the deliverables of the group; that page also includes instructions for disclosing a patent. An individual who has actual knowledge of a patent which the individual believes contains Essential Claim(s) must disclose the information in accordance with section 6 of the W3C Patent Policy.

Table of Contents

1. Introduction

HTML has been in continuous evolution since it was introduced to the Internet in the early 1990’s. Some features were introduced in specifications; others were introduced in software releases. In some respects, implementations and author practices have converged with each other and with specifications and standards, but in other ways, they continue to diverge.

HTML 4 became a W3C Recommendation in 1997. While it continues to serve as a rough guide to many of the core features of HTML, it does not provide enough information to build implementations that interoperate with each other and, more importantly, with a critical mass of deployed content. The same goes for XHTML1, which defines an XML serialization for HTML 4, and DOM Level 2 HTML, which defines JavaScript APIs for both HTML and XHTML. [HTML4] [XHTML1] [DOM2HTML]

The HTML 5 draft reflects an effort, started in 2004, to study contemporary HTML implementations and deployed content. The draft:

  1. Defines a single language called HTML 5 which can be written in a “custom” HTML syntax and in XML syntax.
  2. Defines detailed processing models to foster interoperable implementations.
  3. Improves markup for documents.
  4. Introduces markup and APIs for emerging idioms, such as Web applications.

1.1. Open Issues

HTML 5 is still a draft. The contents of HTML 5, as well as the contents of this document which depend on HTML 5, are still being discussed on the HTML Working Group and WHATWG mailing lists. Some of the open issues include (this list is not exhaustive):

  • De facto semantic definitions for some formerly presentational elements.
  • Details of accessibility and media-independence features, such as the longdesc, alt, summary, and headers attributes.
  • The style attribute.
  • The repetition model.

1.2. Backwards Compatible

HTML 5 is defined in a way that it is backwards compatible with the way user agents handle deployed content. To keep the authoring language relatively simple for authors several elements and attributes are not included as outlined in the other sections of this document, such as presentational elements that are better dealt with using CSS.

User agents, however, will always have to support these older elements and this is why the specification clearly separates requirements for authors and user agents. This means that authors can not use the isindex or plaintext element, but user agents are required to support them in a way that is compatible with how these elements behaved previously.

Since HTML 5 has separate conformance requirements for authors and user agents there is no longer a need for marking things “deprecated”.

1.3. Development Model

The HTML 5 specification will not be considered finished before there are at least two complete implementations of the specification. This is a different approach than previous versions of HTML had. The goal is to ensure that the specification is implementable and usable by designers and developers once it is finished.

2. Syntax

The HTML 5 language has a “custom” HTML syntax that is compatible with HTML 4 and XHTML1 documents published on the Web, but is not compatible with the more esoteric SGML features of HTML 4, such as <em/content/. Documents using this “custom” syntax must be served with the text/html MIME type.

HTML 5 also defines detailed parsing rules (including “error handling”) for this syntax which are largely compatible with popular implementations. User agents will follow these rules for resources that have the text/html MIME type. Here is an example document that conforms to the HTML syntax:

<!doctype html>
    <meta charset="UTF-8">
    <title>Example document</title>
    <p>Example paragraph</p>

The other syntax that can be used for HTML 5 is XML. This syntax is compatible with XHTML1 documents and implementations. Documents using this syntax need to be served with an XML MIME type and elements need to be put in the namespace following the rules set forth by the XML specifications. [XML]

Below is an example document that conforms to the XML syntax of HTML 5. Note that XML documents must have an XML MIME type such as application/xhtml+xml or application/xml.

<?xml version="1.0" encoding="UTF-8"?>
<html xmlns="">
    <title>Example document</title>
    <p>Example paragraph</p>

2.1. Character Encoding

For the HTML syntax of HTML 5 authors have three means of setting the character encoding:

  • At the transport level. By using the HTTP Content-Type header for instance.
  • Using a Unicode Byte Order Mark (BOM) character at the start of the file. This character provides a signature for the encoding used.
  • Using a meta element with a charset attribute that specifies the encoding within the first 512 bytes of the file. <meta charset="UTF-8"> could be used to specify the UTF-8 encoding. This replaces the need for <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">

For the XML syntax authors have to use the rules as set forth in the XML specifications to set the character encoding.

2.2. The DOCTYPE

The HTML syntax of HTML 5 requires a DOCTYPE to be specified to ensure that the browser renders the page in standards mode. The DOCTYPE serves no other purpose and is therefore optional for XML. Documents with an XML MIME type are always handled in standards mode. [DOCTYPE]

The DOCTYPE declaration is <!DOCTYPE html> and is case-insensitive in the HTML syntax. DOCTYPEs from earlier versions of HTML were longer because the HTML language was SGML based and therefore required a reference to a DTD. With HTML 5 this is no longer the case and the DOCTYPE is only needed to enable standards mode for documents written using the HTML syntax. Browsers already do this for <!DOCTYPE html>.

3. Language

This section is split up in several subsections to more clearly illustrate the various differences there are between HTML 4 and HTML 5.

3.1. Content Model Changes

HTML 5 has defined stricter content models for elements such as div and li. These elements now contain either “block level” or “inline level” content, but not both. This change makes HTML consistent in classifying elements according to whether they are used for structuring the page (“block level”) or assigning semantics to text within the structure (“inline level”). This means that the following are allowed:


… but this is not:


… because the p element is block level element and the em element is not.

Another change is that in HTML 5 the tfoot element either appears at the end of a table element or directly after thead.

3.2. New Elements

The following elements have been introduced for better structure:

  • section represents a generic document or application section. It can be used together with h1h6 to indicate the document structure.
  • article represents an independent piece of content of a document, such as a blog entry or newspaper article.
  • aside represents a piece of content that is only slightly related to the rest of the page.
  • header represents the header of a section.
  • footer represents a footer for a section and can contain information about the author, copyright information, et cetera.
  • nav represents a section of the document intended for navigation.
  • dialog can be used to mark up a conversation like this:
     <dt> Costello
     <dd> Look, you gotta first baseman?
     <dt> Abbott
     <dd> Certainly.
     <dt> Costello
     <dd> Who's playing first?
     <dt> Abbott
     <dd> That's right.
     <dt> Costello
     <dd> When you pay off the first baseman every month, who gets the money?
     <dt> Abbott
     <dd> Every dollar of it. 
  • figure can be used to associate a caption together with some embedded content, such as a graphic or video:
     <video src=ogg>…</video>

Then there are several other new elements:

  • audio and video for multimedia content. Both provide an API so application authors can script their own user interface, but there is also a way to trigger a user interface provided by the user agent. source elements are used together with these elements if there are multiple streams available of different types.
  • embed is used for plugin content.
  • m represents a run of marked text.
  • meter represents a measurement, such as disk usage.
  • time represents a date and/or time.
  • canvas is used for rendering dynamic bitmap graphics on the fly, such as graphs, games, et cetera.
  • command represents a command the user can invoke.
  • datagrid represents an interactive representation of a tree list or tabular data.
  • details represents additional information or controls which the user can obtain on demand.
  • datalist together with the a new list attribute for input is used to make comboboxes:
    <input list=browsers>
    <datalist id=browsers>
     <option value="Safari">
     <option value="Internet Explorer">
     <option value="Opera">
     <option value="Firefox">
  • The datatemplate, rule, and nest elements provide a templating mechanism for HTML.
  • event-source is used to “catch” server sent events.
  • output represents some type of output, such as from a calculation done through scripting.
  • progress represents a completion of a task, such as downloading or when performing a series of expensive operations.

The input element’s type attribute now has the following new values:

  • datetime
  • datetime-local
  • date
  • month
  • week
  • time
  • number
  • range
  • email
  • url

The idea of these new types is that the user agent can provide the user interface, such as a calendar date picker or integration with the user’s address book and submit a defined format to the server. It gives the user a better experience as his input is checked before sending it to the server meaning there is less time to wait for feedback.

3.3. New Attributes

HTML 5 has introduced several new attributes to various elements that were already part of HTML 4:

  • The a and area elements now have a media attribute for consistency with the link element. It is purely advisory.
  • The a and area elements have a new attribute called ping that specifies a space separated list of URIs which have to be pinged when the hyperlink is followed. Currently user tracking is mostly done through redirects. This attribute allows the user agent to inform users which URIs are going to be pinged as well as giving privacy-conscious users a way to turn it off.
  • The area element, for consistency, now has the hreflang and rel attributes.
  • The base element can now have a target attribute as well mainly for consistency with the a element and because it was already widely supported. Also, the target attribute for the a and area elements is no longer deprecated, as it is useful in Web applications, for example in conjunction with iframe.
  • The value attribute for the li element is no longer deprecated as it is not presentational. The same goes for the start attribute of the ol element.
  • The meta element has a charset attribute now as this was already supported and provides a nicer way to specify the character encoding for the document.
  • A new autofocus attribute can be specified on the input (except when the type attribute is hidden), select, textarea and button elements. It provides a declarative way to focus a form control during page load. Using this feature should enhance the user experience as the user can turn it off if he does not like it, for instance.
  • The new form attribute for input, output, select, textarea, button and fieldset elements allows for controls to be associated with more than a single form.
  • The input, button and form elements have a new replace attribute which affects what will be done with the document after a form has been submitted.
  • The form and select elements (as well as the datalist element) have a data attribute that allows for automatically prefilling of form controls, in case of form, or the form control, in case of select and datalist, with data from the server.
  • The new required attribute applies to input (except when the type attribute is hidden, image or some button type such as submit) and textarea. It indicates that the user has to fill in a value in order to submit the form.
  • The input and textarea elements have a new attribute called inputmode which gives a hint to the user interface as to what kind of input is expected.
  • You can now disable an entire fieldset by using the disabled attribute on it. This was not possible before.
  • The input element has several new attributes to specify constraints: autocomplete, min, max, pattern and step. As mentioned before it also has a new list attribute which can be used together with the datalist and select element.
  • input and button also have a new template attribute which can be used for repetition templates.
  • The menu element has three new attributes: type, label and autosubmit. They allow the element to transform into a menu as found in typical user interfaces as well as providing for context menus in conjunction with the global contextmenu attribute.
  • The style element has a new scoped attribute which can be used to enable scoped style sheets. Style rules within such a style element only apply to the local tree.
  • The script element has a new attribute called async that influences script loading and execution.
  • The html element has a new attribute called manifest that points to an application cache manifest used in conjunction with the API for offline Web applications.

Several attributes from HTML 4 now apply to all elements. These are called global attributes: class, dir, id, lang, tabindex and title.

There are also several new global attributes:

  • The contenteditable attribute indicates that the element is an editable area. The user can change the contents of the element and manipulate the markup.
  • The contextmenu attribute can be used to point to a context menu provided by the author.
  • The draggable attribute can be used together with the new drag & drop API.
  • The irrelevant attribute indicates that an element is not yet, or is no longer, relevant.

The following are the attributes for the repetition model. These are global attributes and as such may be used on all HTML elements, or on any element in any other namespace, with the attributes being in the namespace.:

  • repeat
  • repeat-start
  • repeat-min
  • repeat-max

HTML 5 also makes all event handler attributes from HTML 4 that take the form onevent-name global attributes and adds several new event handler attributes for new events it defines, such as the onmessage attribute which can be used together with the new event-source element and the cross-document messaging API.

3.4. Changed Elements

These elements have new meanings in HTML 5 which are incompatible with HTML 4. The new meanings better reflect the way they are used on the Web or gives them a purpose so people can start using them.

  • The a element without an href attribute now represents a “placeholder link”.
  • The address element is now scoped by the new concept of sectioning.
  • The b element now represents a span of text to be stylistically offset from the normal prose without conveying any extra importance, such as key words in a document abstract, product names in a review, or other spans of text whose typical typographic presentation is emboldened.
  • The hr element now represents a paragraph-level thematic break.
  • The i element now represents a span of text in an alternate voice or mood, or otherwise offset from the normal prose, such as a taxonomic designation, a technical term, an idiomatic phrase from another language, a thought, a ship name, or some other prose whose typical typographic presentation is italicized. Usage varies widely by language.
  • For the label element the browser should no longer move focus from the label to the control unless such behaviour is standard for the underlying platform user interface.
  • The menu element is redefined to be useful for actual menus.
  • The small element now represents small print (for side comments and legal print).
  • The strong element now represents importance rather than strong emphasis.
  • The alt attribute on the img element is optional under a limited set of circumstances. In general authors should include it.

3.5. Absent Elements

The elements in this section are not to be used by authors. User agents will still have to support them and HTML 5 will get a rendering section in due course that says exactly how. (The isindex element for instance is already supported by the parser.)

The following elements are not in HTML 5 because their effect is purely presentational and therefore better handled by CSS:

  • basefont
  • big
  • center
  • font, although it is allowed when inserted by a WYSIWYG editor due to limitations in the state of the art in user interface for these editors.
  • s
  • strike
  • tt
  • u

The following elements are not in HTML 5 because their usage affected usability and accessibility for the end user in a negative way:

  • frame
  • frameset
  • noframes

The following elements are not included because they have not been used often, created confusion or can be handled by other elements:

  • acronym is not included because it has created lots of confusion. Authors are to use abbr for abbreviations.
  • applet has been obsoleted in favor of object.
  • isindex usage can be replaced by usage of form controls.
  • dir has been obsoleted in favor of ul.

Finally the noscript is only conforming in the HTML syntax. It is not included in the XML syntax as its usage relies on an HTML parser.

3.6. Absent Attributes

Some attributes from HTML 4 are no longer allowed in HTML 5. If they need to have any impact on user agents for compatibility reasons it is defined how they should work in those scenarios.

  • accesskey attribute on a, area, button, input, label, legend and textarea.
  • rev and charset attributes on link and a.
  • shape and coords attributes on a.
  • longdesc attribute on img and iframe.
  • target attribute on link.
  • nohref attribute on area.
  • profile attribute on head.
  • version attribute on html.
  • name attribute on map, img, object, form, iframe, a (use id instead).
  • scheme attribute on meta.
  • archive, classid, codebase, codetype, declare and standby attributes on object.
  • valuetype and type attributes on param.
  • charset and language attributes on script.
  • summary attribute on table.
  • headers, axis and abbr attributes on td and th.
  • scope attribute on td.

In addition, HTML 5 has none of the presentational attributes that were in HTML 4 as they are better handled by CSS:

  • align attribute on caption, iframe, img, input, object, legend, table, hr, div, h1, h2, h3, h4, h5, h6, p, col, colgroup, tbody, td, tfoot, th, thead, tr and body.
  • alink, link, text and vlink attributes on body.
  • background attribute on body.
  • bgcolor attribute on table, tr, td, th and body.
  • border attribute on table, img and object.
  • cellpadding and cellspacing attributes on table.
  • char and charoff attributes on col, colgroup, tbody, td, tfoot, th, thead and tr.
  • clear attribute on br.
  • compact attribute on dl, menu, ol and ul.
  • frame attribute on table.
  • frameborder attribute on iframe.
  • height attribute on iframe, td and th.
  • hspace and vspace attributes on img and object.
  • marginheight and marginwidth attributes on iframe.
  • noshade attribute on hr.
  • nowrap attribute on td and th.
  • rules attribute on table.
  • scrolling attribute on iframe.
  • size attribute on hr, input and select.
  • style attribute on all elements with the exception of font.
  • type attribute on li, ol and ul.
  • valign attribute on col, colgroup, tbody, td, tfoot, th, thead and tr.
  • width attribute on hr, table, td, th, col, colgroup, iframe and pre.

4. APIs

HTML 5 introduces a number of APIs that help in creating Web applications. These can be used together with the new elements introduced for applications:

  • 2D drawing API which can be used with the new canvas element.
  • API for playing of video and audio which can be used with the new video and audio elements.
  • Persistent storage. Both key / value and a SQL database are supported.
  • An API that enables offline Web applications.
  • An API that allows a Web application to register itself for certain protocols or MIME types.
  • Editing API in combination with a new global contenteditable attribute.
  • Drag & drop API in combination with a draggable attribute.
  • Network API.
  • API that exposes the history and allows pages to add to it to prevent breaking the back button. (This API has the necessary security restrictions in place.)
  • Cross document messaging.
  • Server sent events in combination with the event-source element.

4.1. Extensions to HTMLDocument

HTML 5 has extended the HTMLDocument interface from DOM Level 2 HTML in a number of ways. The interface is now implemented on all objects implementing the Document interface so it stays meaningful in a compound document context. It also has several noteworthy new members:

  • getElementsByClassName() to select elements by their class name. The way this method is defined it will allow it to work for any content with class attributes and a Document object such as SVG and MathML.
  • innerHTML as an easy way to parse and serialize an HTML or XML document. This attribute was previously only available on HTMLElement in Web browsers and not part of any standard.
  • activeElement and hasFocus to determine which element is currently focused and whether the Document has focus respectively.
  • getSelection() which returns an object that represents the current selection(s).
  • designMode and execCommand() which are mostly used for editing of documents.

4.2. Extensions to HTMLElement

The HTMLElement interface has also gained several extensions in HTML 5:

  • getElementsByClassName() which is basically a scoped version of the one found on HTMLDocument.
  • innerHTML as found in Web browsers today. It is also defined to work in XML context (when it is used in an XML document).
  • classList is a convenient accessor for className. The object it returns exposes methods, such as has(), add(), remove() and toggle() for manipulating the element’s classes. The a, area and link elements have a similar attribute called relList that provides the same functionality for the rel attribute.


The editor would like to thank Ben Millard, Cameron McCormack, Charles McCathieNevile, Dan Connolly, David Håsäther, Henri Sivonen, James Graham, Maciej Stachowiak, Martijn Wargers, Martyn Haigh, Michael Smith, Olivier Gendrin, Philip Taylor and Simon Pieters for their contributions to this document as well as to all the people who have contributed to HTML 5 over the years for improving the Web!

Categories: HTML, News, Programming