How a new HTML element will make the Web faster

When the browser encounters a Picture element, it first evaluates any rules that the Web developer might specify. (Opera’s developer site has a good article on all the possibilities Picture offers.) Then, after evaluating the various rules, the browser picks the best image based on its own criteria.

via How a new HTML element will make the Web faster | Ars Technica.

How To Create a Pure CSS Dropdown Menu

With the help of some advanced selectors a dropdown menu can be easily created with CSS. Throw in some fancy CSS3 properties and you can create a design that was once only achievable with background images and Javascript. Follow this tutorial to see the step by step process of building your own pure CSS dropdown menu.

via How To Create a Pure CSS Dropdown Menu.

Also here:  Another Simple CSS3 Dropdown Menu

CSS Zen Garden: The Beauty in CSS Design

There is a continuing need to show the power of CSS. The Zen Garden aims to excite, inspire, and encourage participation. To begin, view some of the existing designs in the list. Clicking on any one will load the style sheet into this very page. The HTML remains the same, the only thing that has changed is the external CSS file. Yes, really.

via CSS Zen Garden: The Beauty in CSS Design.

From: 10 Years

Wow. It’s finally happened. The CSS Zen Garden is 10 years old today.

Stop standardizing HTML

It is well past time, though, for the W3C and the browser vendors to stop talking as if they constrain the markup developers can use and focus instead on the many things they can do to make the browsers supporting that markup processing more capable. HTML’s legacy vocabulary is a great foundation on which developers can build their own toolsets. The Web will benefit, however, from letting developers solve their information problems in their own ways, rather than trying to stuff too many things into a single vocabulary.

via Stop standardizing HTML – Programming.

Content hosting for the modern web

In our applications, we take a risk-based approach. Generally speaking, we tend to use three strategies:

  • In higher risk situations (e.g. documents with elevated risk of URL disclosure), we may couple the URL token scheme with short-lived, document-specific cookies issued for specific subdomains of This mechanism, known within Google as FileComp, relies on a range of attack mitigation strategies that are too disruptive for Google applications at large, but work well in this highly constrained use case.
  • In cases where the risk of leaks is limited but responsive access controls are preferable (e.g., embedded images), we may issue URLs bound to a specific user, or ones that expire quickly.
  • In low-risk scenarios, where usability requirements necessitate a more balanced approach, we may opt for globally valid, longer-lived URLs.

via Google Online Security Blog: Content hosting for the modern web.

Chapter 4 The amazing em unit and other best practices

The foremost tool for writing scalable style sheets is the “em” unit, and it therefore goes on top of the list of guidelines that we will compile throughout this chapter: use ems to make scalable style sheets. Named after the letter “M”, the em unit has a long-standing tradition in typography where it has been used to measure horizontal widths. For example, the long dash often found in American texts (–) is known as “em-dash” since it historically has had the same width as the letter “M”. Its narrower cousin (-), often found in European texts is similarly referred to as “en-dash”.

The meaning of “em” has changed over the years. Not all fonts have the letter “M” in them (for example Chinese), but all fonts have a height. The term has therefore come to mean the height of the font – not the width of the letter “M”.

In CSS, the em unit is a general unit for measuring lenghts, for example page margins and padding around elements. You can use it both horizontally and vertically, and this shocks traditional typographers who always have used em exclusively for horizontal measurements. By extending the em unit to also work vertically, it has become a very powerful unit – so powerful that you seldom have to use other length units.

via Chapter 4 The amazing em unit and other best practices.

HTML link tag

Definition and Usage

The <link> tag defines the relationship between a document and an external resource.

The <link> tag is most used to link to style sheets.

Tips and Notes

Note: The <link> element must be embedded in the head section, but it can appear any number of times.

Differences Between HTML and XHTML

In HTML the <link> tag has no end tag.

In XHTML the <link> tag must be properly closed.

via HTML link tag.

HTML span tag

The <span> tag is used to group inline-elements in a document.

The <span> tag provides no visual change by itself.

The <span> tag provides a way to add a hook to a part of a text or a part of a document.

When the text is hooked in a <span> element you can add styles to the content, or manipulate the content with for example JavaScript.

via HTML span tag.

From The SPAN Tag

Use span tags when you don’t want any changes to the layout other than exactly what you specify in the styles of the span. For example, if you use a <div> or <p> most browsers will add space around the element, because they are block elements.