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

[whatwg] Attributes vs. Elements

From: Dean Edridge <dean@55.co.nz>
Date: Tue, 13 Mar 2007 11:39:20 +1300
Message-ID: <45F5D698.9000001@55.co.nz>
On 12 Mar 2007, at 20:19, Andrew Fedoniouk wrote:

> Case:
> <td ><a href="1.htm">xyz</a></td>
> <td ><a href="2.htm">xyz-xyz-xyz</a></td>
> is perfectly valid from some abstract semantic machine
> point of view but for human these two cells are not
> equal. At least hit area is different. And visual perception too.

All you need to do is add this to your CSS:

td > a:link { display: block; }

and the whole cell content area will become clickable (i.e. the area 
interior to the padding. don't use padding on the cell if you want to 
run the clickable area up to the cell's border)

Is this normal behaviour according to the css spec? Because I use this 
method a lot but with li not td. I've never been able to get it to work 
on Opera though. I just thought that it was a case of Opera sticking to 
the spec and the others not. Once the cursor is over the text in a it's 
fine, but just hovering over the li does nothing.

Dean
Received on Monday, 12 March 2007 15:39:20 UTC

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