NameSilo

Question Regarding CSS

NamecheapNamecheap
Watch

The Equivocate

Established Member
Impact
13
I have style.css that defines the link style:

Code:
A:link {
	color : #FFC20C;
	font-family : Arial;
	font-size : 11px;
	font-weight : normal;
	font-style : normal;
	text-decoration : none;
	}
A:visited {
	color : #FFC20C;
	font-family : Arial;
	font-size : 11px;
	font-weight : normal;
	font-style : normal;	
	text-decoration : none;
	}
A:hover {
	color : #FFC20C;
	font-family : Arial;
	font-size : 11px;
	font-weight : normal;
	font-style : normal;
text-decoration : underline;
	}

But I want to add a different type of link for a different part on the page. I added this to style.css:

Code:
.news {
	color : #FFC20C;
	font-family : Arial;
	font-size : 14px;
	font-weight : bold;
	font-style : normal;
	text-decoration : none;
	}
	
	A.news:link {
	color : #FFC20C;
	font-family : Arial;
	font-size : 14px;
	font-weight : bold;
	font-style : normal;
	text-decoration : none;
	}
A.news:visited {
	color : #FFC20C;
	font-family : Arial;
	font-size : 14px;
	font-weight : bold;
	font-style : normal;	
	text-decoration : none;
	}
A.news:hover {
	color : #FFC20C;
	font-family : Arial;
	font-size : 14px;
	font-weight : bold;
	font-style : normal;
text-decoration : underline;
	}

And then in CuteNews I did this (keep in mind CuteNews has their own little replacements, [link] is like on vB): [code]<span style="news...ew style, but the link remains the old style.
 
0
•••
The views expressed on this page by users and staff are their own, not those of NamePros.
Unstoppable Domains โ€” AI StorefrontUnstoppable Domains โ€” AI Storefront
You aren't far off, heres what I do:

Code:
A.news:link, A.news:visited, A.news:active { 
/*I have added them all in one line as they are all the same anyway!*/
	color : #FFC20C;
	font-family : Arial;
	font-size : 14px;
	font-weight : bold;
	font-style : normal;
	text-decoration : none;
	}
A.news:hover {
	color : #FFC20C;
	font-family : Arial;
	font-size : 14px;
	font-weight : bold;
	font-style : normal;
                text-decoration : underline;
	}


And then for the link, you should do the normal a href tag but add class"classname" like this:

Code:
<a class="news" href="http://www.now-design.co.uk/">Web Design UK</a>
 
0
•••
Here's the problem with that - since I am using a news script, the link is generated inside CuteNews - there's no <a> tag for me to edit.
 
0
•••
Dynadot โ€” .com TransferDynadot โ€” .com Transfer
Appraise.net
Escrow.com
Spaceship
Rexus Domain
CryptoExchange.com
Domain Recover
CatchDoms
NameMaxi - Your Domain Has Buyers
DomDB
  • The sidebar remains visible by scrolling at a speed relative to the pageโ€™s height.
Back