W3C home > Mailing lists > Public > public-html@w3.org > June 2007

Re: HTML5 differences from HTML4 editor's draft

From: Lachlan Hunt <lachlan.hunt@lachy.id.au>
Date: Mon, 25 Jun 2007 03:01:09 +1000
Message-ID: <467EA355.20301@lachy.id.au>
To: Johannes Lichtenberger <jl@nabooisland.com>
CC: HTML WG <public-html@w3.org>

Johannes Lichtenberger wrote:
>> http://dev.w3.org/cvsweb/~checkout~/html5/html4-differences/Overview.html
> 
> I don't really understand what "The a element without an href attribute now 
> represents a "placeholder link"." means, I can't really imagine what a 
> placeholder link should be or what it's used for.

It just means that it's where a link would ordinarily be, but currently 
isn't.  For example:

<menu>
   <li><a href="/">Home</a>
   <li><a>Products</a>
   <li><a href="/services">Services</a>
   <li><a href="/about">About</a>
</menu>

In this example, Products is a place holder link to the current page. 
It's a way keep the menu the same, without actually linking to the 
current page.

One advantage is that allows to you easily style it differently from the 
other links, to indicate that it is the current page, without requiring 
an additional class.  e.g.

menu a { /* Styles for current page */ }
menu a:link { /* Styles for other links */ }

-- 
Lachlan Hunt
http://lachy.id.au/
Received on Sunday, 24 June 2007 17:01:22 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Wednesday, 9 May 2012 00:16:01 GMT