W3C home > Mailing lists > Public > whatwg@whatwg.org > March 2007

[whatwg] href attribute

From: Andrew Fedoniouk <news@terrainformatica.com>
Date: Sun, 11 Mar 2007 15:56:23 -0800
Message-ID: <004201c76438$f1d9afb0$3501a8c0@TERRA>

----- Original Message ----- 
From: "Anne van Kesteren" <annevk@opera.com>
To: "Daniel Glazman" <daniel.glazman at disruptive-innovations.com>
Cc: "WHATWG" <whatwg at whatwg.org>
Sent: Sunday, March 11, 2007 11:52 AM
Subject: Re: [whatwg] href attribute


> On Sun, 11 Mar 2007 06:03:02 +0100, Daniel Glazman 
> <daniel.glazman at disruptive-innovations.com> wrote:
>>> In any case not all <a>'s are hyperlinks so for your meaning of 
>>> semantic they should also not be automatically hyperlinks (or anchors 
>>> if you wish). I am pretty sure that existence of 'href' attribute is 
>>> what creates semantic meaning of <a> for you. So why <a> cannot be <b 
>>> href> or <c href>?
>>
>> Let me also play the devil (I love it) : a feature is not trashable
>> only because it comes from XHTML 2.0 :-)
>
> I agree. One of the reasons HTML5 has <section> and redefined <h1>-<h6>.
>
>
>> Here, a global href is a really cool idea, we should have done it in
>> HTML 4 but we were too blind to see.
>
> What are the problems it solves? To my mind introducing it will just break 
> compatibility and complicate implementations for no apparent benefit. You 
> also get to deal with silly cases like:

There are many cases when hyperlink-head needs to be a block level
element. Not all contexts in html allow inline elements to appear.
And <a>, as inline element, by itself cannot contain block elements.
Example #1
<a><table>...</table></a> is not acceptable.
<a><td>...</td></a> is not acceptable.

Example #2
<ul>
   <a><li>...</li></a>
</ul>
in this example the desire is to declare the whole rectangle of li to be
a link, not just textual portion of it.  Think about tabs implementation
where each tab is a rectangle with clear visual borders. human
would expect that the whole area inside the borders (included)
of the tab  is a clickable area.

"... and complicate implementations..."

I do not know of how this is implemented in Opera but in my
case to support href globally is a matter of changing:
  a:link { behavior: hyperlink; }
to
  :link { behavior: hyperlink; }
in master style sheet.

I beleive that each modern and modular UA has similar
mechanism of assigning "behavior handlers".

>
>   <input type=checkbox href=http://www.opera.com/>
>

Think about this:

<input type=checkbox href=http://www.opera.com/help/checkbox/explanation
  target="_new">
links like this can be used for contextual help and for me is perfectly 
valid
use case.

It is matter of UA implementation of how to support multiple behaviors
on the same element but it is feasible.

Andrew Fedoniouk.
http://terrainformatica.com


>
> HTML5 already redefines <a> to be hyperlink or a placeholder for one (this 
> should address your concern raised in another e-mail). The idea of <a 
> name=""> is not mentioned in the draft and isn't even conforming (although 
> I suppose user agents will be required to support it). Any element can be 
> a link target much like in HTML4.
>
>
> -- 
> Anne van Kesteren
> <http://annevankesteren.nl/>
> <http://www.opera.com/>
> 
Received on Sunday, 11 March 2007 16:56:23 UTC

This archive was generated by hypermail 2.4.0 : Wednesday, 22 January 2020 16:58:53 UTC