W3C home > Mailing lists > Public > site-comments@w3.org > May 2012

RE: [site-comments] <none> - A elements do not inherit from BODY

From: Jordan Clark <clarky_y2k@hotmail.com>
Date: Sun, 20 May 2012 12:45:11 +0000
Message-ID: <BAY149-W51D076AD67F62ABD520060BE1C0@phx.gbl>
To: W3C Site Comments <site-comments@w3.org>
CC: <lerura@mail-online.dk>


Hi Lars,


What you are describing is *not* a bug: hyperlinks
(A elements) are not meant to inherit colours from BODY styles 
this is actually by design, so that users can see that the content is
not just normal text represents a clickable link to another location.


To get the desired affect, try this CSS:


a { color: green; }


(Although I'd advise as recommended by W3C
accessibility recommendations, that you choose a different colour
than the reset of the text to make it stand out.)


You can also apply all kinds of cool effects to
links, which is way beyond the scope of this question, However, see
Section 5 of the "CSS 2.1 Specification" on selectors for
more info. In particular, see:



"5.11.2  The link pseudo-classes: :link and :visited"
        http://www.w3.org/TR/CSS2/selector.html#link-pseudo-classes



"5.11.3  The dynamic pseudo-classes: :hover, :active, and
:focus"
       
http://www.w3.org/TR/CSS2/selector.html#dynamic-pseudo-classes


Hope this helps!

Regards,
Jordan Clark.


Web: http://www.jdclark.org
Mail: mail@jdclark.org



From: lerura@mail-online.dk
Date: Sat, 19 May 2012 05:41:21 +0000
To: site-comments@w3.org
Subject: [site-comments] <none>



	I dont know if it is the right place to report the bug (I believe) I 
discovered but here it is:

	 

	<a>s do not inherit  color:

	 

	example:

	<!DOCTYPE html>

	<html>

	<head>

	<title></title>

	<style>

	body {

	font-size:72px;

	font-family:Arial;

	font-style:italic;

	color:green;

	text-transform:uppercase;

	}

	</style></head>

	<body>

	Somehow

	<a href="/">Somewhere</a>

	<del>Something</del>

	<span>Sometext</span>

	</body>

	</html>

	 

	all other properties are inherited as expected.

	 

Annonce:


Gratis email til alle overalt: www.mail-online.dk


    Find dit perfekte match: www.vipdaters.dk


 		 	   		  
Received on Sunday, 20 May 2012 12:45:42 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Wednesday, 24 October 2012 16:21:34 GMT