Member Avatar for Borderline

My navigation system consists of a main bar, which changes colour when a mouse hovers over it. Clicking this link results in a secondary menu appearing, in silver/white.

However, the content background is white, so these link colours aren't suitable. I have tried changing my CSS code so that the link colours are different for items within the content div, but haven't pulled it off as yet. I was hoping someone could point me in the right direction.

Page Code:

<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Further Flight</title>
<link rel="stylesheet" type="text/css" href="http://www.further-flight.co.uk/style/20080820.css"/>
</head>

<body>

<div id="secondary"><?php include($_SERVER['DOCUMENT_ROOT'].'/style/secondary_previews.php');?></div>
<div id="header"><?php include($_SERVER['DOCUMENT_ROOT'].'/style/header.php');?></div>
<div id="logo"><?php include($_SERVER['DOCUMENT_ROOT'].'/style/logo.php');?></div>
<div id="navigation"><?php include($_SERVER['DOCUMENT_ROOT'].'/style/main.php');?></div>

<div id="content">
	<h2>Overview of Jackpot Previews</h2>

	<p>	
	<a class="content">

	Our resident columnist Pip, from Lodgehill Stables, selects three races a night to preview.  As soon as racing
	begins, we hope to bring this popular feature back to your screens!

	</p></a>
</div>

CSS Code:

/*------  BASIC LAYOUT  ------*/

#secondary{
	margin: 0px 0px 0px 0px;
	width: 100%;
	height: 15px;
	font: 0.7em arial, verdana, sans-serif;
	background-color: #494949;
	padding: 5px 0px 5px 0px;
	text-indent: 10px;
	color: silver;
}

#logo{
	height: 80px;
	background-color: #000000;
	z-index: 1;
}

#header{
	position: absolute;
	top: 20px;
	right: 50px;
	text-align: right;
	z-index: 2;
}

#footer{
	background: url(/images/footer.png) repeat-x;
	text-align: center;
	padding: 10px 0;
	font: bold 0.8em arial, verdana, sans-serif;
	text-align: center;
	color: #FFFFFF;
	border: 1px solid #000000;
}


/*------  ELEMENTS AND TAGS  ------*/

a:link {
	color: white;
	text-decoration:none;
}

a:visited {
	color: silver;
	text-decoration:none;
}

a:hover {
	color:silver;
	text-decoration:bold;
}

body {
	background-image: url("/images/20080820_back1.png");
	background-repeat: repeat;
}

h1	{
	color: #FFFFFF;
	font: 2em arial, verdana, sans-serif;
	letter-spacing: 2px;
}

h2	{
	color: #C0C0C0;
	font: 0.9em arial, verdana, sans-serif;
}








/*------  CONTENT BOXES  ------*/

div#content {
	margin-top: 30px;
	padding: 20px;
	border: 1px solid #000000;
	background: #FFFFFF;
	font: 0.8em arial, verdana, sans-serif;
	}

div#content h2 {
	position: relative;
	float: left;
	margin: -38px 0 15px 0;
	padding: 8px;
	border: 1px solid #000000;
	background: black url(/images/blockactive.gif) center center repeat-x;
	font: bold 1em arial, verdana, sans-serif;
	color: #FFFFFF;
	}

div#content h1 {
	font: bold 0.8em arial, verdana, sans-serif;
	color: #000000;
	}

div#content p {
	clear: left;
	color: #000000;
	text-align: justify;
	}

		a.content:link {
			color: blue;
			text-decoration:none;
		}

		a.content:visited {
			color: purple;
			text-decoration:none;
		}

		a.content:hover {
			color:red;
			text-decoration:bold;
		}

Recommended Answers

All 2 Replies

Oops, ignore my reply. I wasn't able to answer your question x_X

Browsers have accessibility settings to disable changing the colors of links. Check your settings.

Link color metastyles are global in nature.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.